converts the doc informations into unicode

This commit is contained in:
Emmanuel Garette 2017-01-10 12:16:08 +01:00
parent 7fe47396ee
commit e71beac4dc
3 changed files with 7 additions and 2 deletions

View File

@ -1,3 +1,6 @@
Thu Jan 10 11:55:02 2017 +0200 Gwenael Remond <gremond@cadoles.com>
* converts the doc informations into unicode
Mon Jan 9 20:12:02 2017 +0200 Emmanuel Garette <egarette@cadoles.com> Mon Jan 9 20:12:02 2017 +0200 Emmanuel Garette <egarette@cadoles.com>
* make_dict has new fullpath option * make_dict has new fullpath option

View File

@ -49,4 +49,4 @@ gettext.translation(APP_NAME, fallback=True)
t = gettext.translation(APP_NAME, fallback=True) t = gettext.translation(APP_NAME, fallback=True)
_ = t.gettext _ = t.ugettext

View File

@ -73,6 +73,8 @@ class StorageBase(object):
_setattr = object.__setattr__ _setattr = object.__setattr__
_setattr(self, '_name', name) _setattr(self, '_name', name)
if doc is not undefined: if doc is not undefined:
if isinstance(doc, str):
doc = doc.decode('utf8')
_setattr(self, '_informations', {'doc': doc}) _setattr(self, '_informations', {'doc': doc})
if multi != 1: if multi != 1:
_setattr(self, '_multi', multi) _setattr(self, '_multi', multi)