fix: [language] libretranslate unreachable

This commit is contained in:
terrtia 2023-12-07 14:59:40 +01:00
parent 25c467f11a
commit cea96863ba
No known key found for this signature in database
GPG key ID: 1E1B1F50D84613D0

View file

@ -313,8 +313,10 @@ class LanguageTranslator:
translation = None translation = None
return translation return translation
try:
LIST_LANGUAGES = LanguageTranslator().languages() LIST_LANGUAGES = LanguageTranslator().languages()
except Exception:
LIST_LANGUAGES = []
def get_translation_languages(): def get_translation_languages():
return LIST_LANGUAGES return LIST_LANGUAGES