mirror of
https://github.com/onionshare/onionshare.git
synced 2024-10-01 01:35:40 -04:00
Fix "KeyError: 'fr'" in desktop strings.py
This commit is contained in:
parent
357e3efead
commit
e9ef087c8f
@ -43,7 +43,11 @@ def load_strings(common, locale_dir):
|
||||
current_locale = common.settings.get("locale")
|
||||
strings = {}
|
||||
for s in translations[default_locale]:
|
||||
if s in translations[current_locale] and translations[current_locale][s] != "":
|
||||
if (
|
||||
current_locale in translations
|
||||
and s in translations[current_locale]
|
||||
and translations[current_locale][s] != ""
|
||||
):
|
||||
strings[s] = translations[current_locale][s]
|
||||
else:
|
||||
strings[s] = translations[default_locale][s]
|
||||
|
Loading…
Reference in New Issue
Block a user