feature/Renamed props language_tag to default_locale, default is en_GB

This commit is contained in:
Marko Milić 2023-02-23 11:45:42 +01:00
parent 244fd9ae22
commit 25412cf692
2 changed files with 6 additions and 2 deletions

View File

@ -178,4 +178,8 @@ dev.port=8082
# oauth2.jws_alg=ES256
# oauth2.jwk_private_key=
# Example of the above value: {"kty":"EC","d":"mQ6yDqYB84z027rZoKnr9JIloX7QqyM0QDScHmWIb-s","use":"sig","crv":"P-256","kid":"c14e9b43-d69b-431e-a90b-eac0dd2e59f8","x":"mNBOFk1w7EYZ194LPCKlNn-NbflCkdxPHGh3VmCj13U","y":"4oXertw5ECdy_ApfG_LG5n92Q9-QlPr9Bt3eM_Z9DeI","alg":"ES256"}
# ------------------------------ Identity Provider OAuth2 Props end --------------------------
# ------------------------------ Identity Provider OAuth2 Props end --------------------------
# Please note that depricated name ot this props is: language_tag
default_locale = en_GB

View File

@ -17,7 +17,7 @@ object I18NUtil {
}
def getLocale(): Locale = Locale.getAvailableLocales().toList.filter { l =>
l.toLanguageTag == Props.get("language_tag", "en-GB")
l.toLanguageTag == Props.get("default_locale", "en-GB")
}.headOption.getOrElse(Locale.ENGLISH)
def currentLocale() : Locale = {