Do not fail is lang is not set
This commit is contained in:
parent
03ef9c034e
commit
0d6760b194
@ -155,7 +155,10 @@ class Bundle:
|
|||||||
|
|
||||||
def _get_linfo_file(self):
|
def _get_linfo_file(self):
|
||||||
linfo_file = None
|
linfo_file = None
|
||||||
|
|
||||||
lang = locale.getdefaultlocale()[0]
|
lang = locale.getdefaultlocale()[0]
|
||||||
|
if not lang:
|
||||||
|
return None
|
||||||
|
|
||||||
if os.path.isdir(self._path):
|
if os.path.isdir(self._path):
|
||||||
linfo_path = os.path.join(self.get_locale_path(), lang, 'activity.linfo')
|
linfo_path = os.path.join(self.get_locale_path(), lang, 'activity.linfo')
|
||||||
|
Loading…
Reference in New Issue
Block a user