mirror of
https://github.com/YunoHost/moulinette.git
synced 2024-09-03 20:06:31 +02:00
[mod] add more message to inform users that some stuff are a warning
This commit is contained in:
parent
da00fc9eb0
commit
a8966b8643
1 changed files with 2 additions and 2 deletions
|
@ -92,7 +92,7 @@ class Translator(object):
|
|||
try:
|
||||
return self._translations[self.locale][key].encode('utf-8').format(*args, **kwargs)
|
||||
except KeyError as e:
|
||||
logger.exception("Failed to format translated string '%s' with error: %s" % (key, e))
|
||||
logger.exception("Failed to format translated string '%s' with error: %s (don't panic this is just a warning)" % (key, e))
|
||||
failed_to_format = True
|
||||
|
||||
if failed_to_format or (self.default_locale != self.locale and key in self._translations.get(self.default_locale, {})):
|
||||
|
@ -102,7 +102,7 @@ class Translator(object):
|
|||
try:
|
||||
return self._translations[self.default_locale][key].encode('utf-8').format(*args, **kwargs)
|
||||
except KeyError as e:
|
||||
logger.exception("Failed to format translatable string '%s' with error: %s" % (key, e))
|
||||
logger.exception("Failed to format translatable string '%s' with error: %s (don't panic this is just a warning)" % (key, e))
|
||||
return self._translations[self.locale][key].encode('utf-8')
|
||||
|
||||
logger.exception("unable to retrieve key '%s' for default locale '%s' (don't panic this is just a warning)",
|
||||
|
|
Loading…
Add table
Reference in a new issue