special handling for __ attributes

git-svn-id: svn://svn.cy55.de/Zope3/src/loops/trunk@3173 fd906abe-77d9-0310-91a1-e0d9ade77398
This commit is contained in:
helmutm 2009-01-22 18:39:32 +00:00
parent 2a656daa02
commit f7960ab7ff

View file

@ -130,7 +130,7 @@ class I18NAdapterBase(AdapterBase):
return getI18nValue(self.context, '_' + attr, langInfo)
def __setattr__(self, attr, value):
if attr in self._adapterAttributes:
if attr.startswith('__') or attr in self._adapterAttributes:
object.__setattr__(self, attr, value)
else:
langInfo = attr in self.i18nAttributes and self.languageInfo or None