diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/browse/source/browse/BrowseSourcePresenter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/browse/source/browse/BrowseSourcePresenter.kt index e5c8939b9..87cacb73d 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/browse/source/browse/BrowseSourcePresenter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/browse/source/browse/BrowseSourcePresenter.kt @@ -202,6 +202,10 @@ open class BrowseSourcePresenter( val result = db.insertManga(newManga).executeAsBlocking() newManga.id = result.insertedId() localManga = newManga + } else if (!localManga.favorite) { + // if the manga isn't a favorite, set its display title from source + // if it later becomes a favorite, updated title will go to db + localManga.title = sManga.title } return localManga } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/browse/source/globalsearch/GlobalSearchPresenter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/browse/source/globalsearch/GlobalSearchPresenter.kt index a2391459b..8a47af86b 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/browse/source/globalsearch/GlobalSearchPresenter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/browse/source/globalsearch/GlobalSearchPresenter.kt @@ -267,6 +267,10 @@ open class GlobalSearchPresenter( val result = db.insertManga(newManga).executeAsBlocking() newManga.id = result.insertedId() localManga = newManga + } else if (!localManga.favorite) { + // if the manga isn't a favorite, set its display title from source + // if it later becomes a favorite, updated title will go to db + localManga.title = sManga.title } return localManga } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaPresenter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaPresenter.kt index bb051b605..44d989821 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaPresenter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaPresenter.kt @@ -204,6 +204,10 @@ class MangaPresenter( val sManga = networkManga.toSManga() manga.prepUpdateCover(coverCache, sManga, manualFetch) manga.copyFrom(sManga) + if (!manga.favorite) { + // if the manga isn't a favorite, set its title from source and update in db + manga.title = sManga.title + } manga.initialized = true db.insertManga(manga).executeAsBlocking()