From 02296985d65950f908ea3fcbc7668e2efec0931f Mon Sep 17 00:00:00 2001 From: Ahmad Ansori Palembani Date: Wed, 18 Dec 2024 11:29:55 +0700 Subject: [PATCH] chore(chapter): No longer set last_update as newest chapter's date_upload Grab this info from SQL instead --- .../kanade/tachiyomi/util/chapter/ChapterSourceSync.kt | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/chapter/ChapterSourceSync.kt b/app/src/main/java/eu/kanade/tachiyomi/util/chapter/ChapterSourceSync.kt index f105fcbb2e..987d76c91b 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/chapter/ChapterSourceSync.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/chapter/ChapterSourceSync.kt @@ -118,12 +118,7 @@ suspend fun syncChaptersWithSource( // Return if there's nothing to add, delete or change, avoid unnecessary db transactions. if (toAdd.isEmpty() && toDelete.isEmpty() && toChange.isEmpty()) { - val newestDate = dbChapters.maxOfOrNull { it.date_upload } ?: 0L - if (newestDate != 0L && newestDate > manga.last_update) { - manga.last_update = newestDate - val update = MangaUpdate(manga.id!!, lastUpdate = newestDate) - updateManga.await(update) - } + // TODO: Predict when the next chapter gonna release return Pair(emptyList(), emptyList()) } @@ -189,6 +184,8 @@ suspend fun syncChaptersWithSource( } } + // TODO: Predict when the next chapter gonna release + // Set this manga as updated since chapters were changed // Note that last_update actually represents last time the chapter list changed at all // Those changes already checked beforehand, so we can proceed to updating the manga