handle if LANG is not set

This commit is contained in:
2022-02-09 16:09:23 +01:00
parent c470ca4ed1
commit e0b558b5c3

View File

@@ -6,7 +6,7 @@ from raven.pluginregistry import PluginRegistry
from raven.settings.settingsstore import SettingsStore
settings = SettingsStore.load()
locale = os.environ['LANG'] if os.environ['LANG'] else "en"
locale = os.environ['LANG'] if 'LANG' in os.environ and os.environ['LANG'] else "en"
locale = settings.session.get('general', 'lang', fallback=locale)
_ = False