diff --git a/product/ERP5Type/patches/Localizer.py b/product/ERP5Type/patches/Localizer.py index d169ef26b9adbacd2db238520ec14534143f1446..8f247350dceca14ec0d7b260d7a81f5efcb66f93 100755 --- a/product/ERP5Type/patches/Localizer.py +++ b/product/ERP5Type/patches/Localizer.py @@ -65,7 +65,9 @@ def Localizer_translate(self, domain, msgid, mapping=None, *args, **kw): # Map the translated string with given parameters if type(mapping) is type({}): - return Template(translated_str).substitute(mapping) + if isinstance(translated_str, unicode) : + translated_str = translated_str.encode('utf8') + return unicode(Template(translated_str).substitute(mapping), 'utf8') return translated_str def GlobalTranslationService_translate(self, domain, msgid, *args, **kw):