From 50b282f58ba37dd927a71c93a2a70938358e139a Mon Sep 17 00:00:00 2001 From: nicki <72807749+curche@users.noreply.github.com> Date: Sat, 21 Aug 2021 20:21:20 +0530 Subject: [PATCH] update Anilist tracking title during refresh (#5760) Co-authored-by: Andreas Co-authored-by: Andreas --- .../main/java/eu/kanade/tachiyomi/data/track/anilist/Anilist.kt | 1 + .../java/eu/kanade/tachiyomi/data/track/anilist/AnilistModels.kt | 1 + 2 files changed, 2 insertions(+) diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/track/anilist/Anilist.kt b/app/src/main/java/eu/kanade/tachiyomi/data/track/anilist/Anilist.kt index 5bf89720ec..c2f5746000 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/track/anilist/Anilist.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/track/anilist/Anilist.kt @@ -182,6 +182,7 @@ class Anilist(private val context: Context, id: Int) : TrackService(id) { override suspend fun refresh(track: Track): Track { val remoteTrack = api.getLibManga(track, getUsername().toInt()) track.copyPersonalFrom(remoteTrack) + track.title = remoteTrack.title track.total_chapters = remoteTrack.total_chapters return track } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/track/anilist/AnilistModels.kt b/app/src/main/java/eu/kanade/tachiyomi/data/track/anilist/AnilistModels.kt index 5911361fd5..2d97583448 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/track/anilist/AnilistModels.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/track/anilist/AnilistModels.kt @@ -51,6 +51,7 @@ data class ALUserManga( fun toTrack() = Track.create(TrackManager.ANILIST).apply { media_id = manga.media_id + title = manga.title_user_pref status = toTrackStatus() score = score_raw.toFloat() started_reading_date = start_date_fuzzy