Fix detaction of pt-br system language
This commit is contained in:
parent
00cf1badfc
commit
b089355b5a
1 changed files with 3 additions and 1 deletions
|
@ -91,7 +91,9 @@ class Config(object):
|
|||
|
||||
try:
|
||||
language, enc = locale.getdefaultlocale()
|
||||
language = language.split("_")[0]
|
||||
language = language.lower().replace("_", "-")
|
||||
if language not in ["pt-br"]:
|
||||
language = language.split("-")[0]
|
||||
except Exception:
|
||||
language = "en"
|
||||
|
||||
|
|
Loading…
Reference in a new issue