Skip to content

Commit

Permalink
fix: Portuguese and Chinese map language change not working bug fix
Browse files Browse the repository at this point in the history
ALS-1889
  • Loading branch information
shah272728 committed Nov 22, 2024
1 parent 3ec6a08 commit cf76ba0
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion app/src/main/java/com/aws/amazonlocation/utils/MapHelper.kt
Original file line number Diff line number Diff line change
Expand Up @@ -1523,7 +1523,12 @@ class MapHelper(
}

private fun setStyleLanguage(style: Style) {
val languageCode = getLanguageCode()
var languageCode = getLanguageCode()
if (languageCode != null) {
if (languageCode.contains("-")) {
languageCode = languageCode.split("-")[0]
}
}
val expression: Expression? = Expression.coalesce(
Expression.get("name:$languageCode"),
Expression.get("name:en"),
Expand Down

0 comments on commit cf76ba0

Please sign in to comment.