Change return value of SyncChaptersWithSource.await() (#7715)
* Change return value of `SyncChaptersWithSource.await()`
`updatedToAdd.subtract(reAdded).toList()` never worked as at this point `updatedToAdd` contained ids from db where `reAdded` had default one. Was the same case before the rewrite.
Removed `toDelete` from return value as it was not being used anywhere
* Add doc string
* Use HashSet
Co-authored-by: stevenyomi <95685115+stevenyomi@users.noreply.github.com>
Co-authored-by: stevenyomi <95685115+stevenyomi@users.noreply.github.com>
(cherry picked from commit 11f640cfee)
# Conflicts:
# app/src/main/java/eu/kanade/tachiyomi/data/library/LibraryUpdateService.kt
# app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaPresenter.kt
This commit is contained in:
@@ -209,7 +209,7 @@ class EHentaiUpdateWorker(private val context: Context, workerParams: WorkerPara
|
||||
val newChapters = source.getChapterList(manga.toMangaInfo())
|
||||
.map { it.toSChapter() }
|
||||
|
||||
val (new, _) = syncChaptersWithSource.await(newChapters, manga, source)
|
||||
val new = syncChaptersWithSource.await(newChapters, manga, source)
|
||||
return new to getChapterByMangaId.await(manga.id)
|
||||
} catch (t: Throwable) {
|
||||
if (t is EHentai.GalleryNotFoundException) {
|
||||
|
||||
Reference in New Issue
Block a user