Skip to content

Commit

Permalink
use episode titles from kitsu if kitsu doesn't have episode titles us…
Browse files Browse the repository at this point in the history
…e anime source titles (#146)
  • Loading branch information
KawsarDev authored Jan 20, 2024
1 parent 8067e0d commit 3c992f8
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions app/src/main/java/ani/dantotsu/media/anime/AnimeWatchFragment.kt
Original file line number Diff line number Diff line change
Expand Up @@ -208,12 +208,9 @@ class AnimeWatchFragment : Fragment() {
}
if (media.anime?.kitsuEpisodes != null) {
if (media.anime!!.kitsuEpisodes!!.containsKey(i)) {
episode.desc =
episode.desc ?: media.anime!!.kitsuEpisodes!![i]?.desc
episode.title =
episode.title ?: media.anime!!.kitsuEpisodes!![i]?.title
episode.thumb =
episode.thumb ?: media.anime!!.kitsuEpisodes!![i]?.thumb
episode.desc = media.anime!!.kitsuEpisodes!![i]?.desc ?: episode.desc
episode.title = media.anime!!.kitsuEpisodes!![i]?.title ?: episode.title
episode.thumb = media.anime!!.kitsuEpisodes!![i]?.thumb
?: FileUrl[media.cover]
}
}
Expand Down Expand Up @@ -568,4 +565,4 @@ class AnimeWatchFragment : Fragment() {
const val EXTRA_EPISODE_NUMBER = "extra_episode_number"
}

}
}

0 comments on commit 3c992f8

Please sign in to comment.