Browse Source

Fix getPreferredSeason() (again)

fix selection of preferred season for languages other than english
pull/49/head
Jannik 4 months ago
parent
commit
be1c001942
Signed by: Seil0
GPG Key ID: E8459F3723C52C24
  1. 2
      app/src/main/java/org/mosad/teapod/parser/crunchyroll/DataTypes.kt

2
app/src/main/java/org/mosad/teapod/parser/crunchyroll/DataTypes.kt

@ -226,7 +226,7 @@ data class Seasons(
fun getPreferredSeason(local: Locale): Season {
return items.firstOrNull { season ->
// try to get the the first seasons which matches the preferred local
season.slugTitle.endsWith("${local.displayLanguage}-dub", true)
season.slugTitle.endsWith("${local.getDisplayLanguage(Locale.ENGLISH)}-dub", true)
} ?: items.firstOrNull { season ->
// if there is no season with the preferred local, try to find a subbed season
season.isSubbed

Loading…
Cancel
Save

Du besuchst diese Seite mit einem veralteten IPv4-Internetzugang. Möglicherweise treten in Zukunft Probleme mit der Erreichbarkeit und Performance auf. Bitte frage deinen Internetanbieter oder Netzwerkadministrator nach IPv6-Unterstützung.
You are visiting this site with an outdated IPv4 internet access. You may experience problems with accessibility and performance in the future. Please ask your ISP or network administrator for IPv6 support.
Weitere Infos | More Information
Klicke zum schließen | Click to close