Commit 56af85cf authored by Julien Muchembled's avatar Julien Muchembled

fixup! ERP5Type: make sure the correct __setattr__ is used when the class is still ghost

parent 468541e9
......@@ -125,6 +125,8 @@ class GhostBaseMetaClass(ExtensionClass, AccessorHolderType):
correct __setattr__ is used. For example, without this, a broken object
(ERP5BaseBroken) would not raise.
"""
if name.startswith(('_p_', '_v_')):
return super(cls, self).__setattr__(name, value)
self.__class__.loadClass()
setattr(self, name, value)
cls.__setattr__ = __setattr__
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment