Sort language lists by the localized language name (#2991)

This commit is contained in:
Levi Bard 2022-12-05 14:49:09 +01:00 committed by GitHub
parent f3962058dc
commit 11de43f470
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -82,7 +82,7 @@ fun getLocaleList(initialLanguage: String): List<Locale> {
it.country.isNullOrEmpty() &&
it.script.isNullOrEmpty() &&
it.variant.isNullOrEmpty()
}
}.sortedBy { it.displayName }
)
ensureLanguageIsFirst(locales, initialLanguage)
return locales