Commit 099b6e29 authored by Romain Courteaud's avatar Romain Courteaud

None may not be always considered as a NULL value of property, so it's better...

None may not be always considered as a NULL value of property, so it's better to take a default NULL value from _null.
Value is considered a NULL if inside _null.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@13562 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 795dde0e
......@@ -143,8 +143,9 @@ class Getter(Method):
default = args[0]
else:
default = self._default
value = getattr(aq_base(instance), self._storage_id, None) # No acquisition on properties
if value is not None:
# No acquisition on properties
value = getattr(aq_base(instance), self._storage_id, self._null[0])
if value not in self._null:
if self._is_tales_type and kw.get('evaluate', 1):
return evaluateTales(instance, value)
else:
......
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