Commit 250f0667 authored by Jérome Perrin's avatar Jérome Perrin

Proxify tool:

 handle the case of None values in copy
 fix the problem of removing some keys while iterating on the dictionnary



git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@15661 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 94ffabf1
......@@ -667,8 +667,8 @@ class ERP5Form(ZMIForm, ZopePageTemplate):
value = Method(value.method_name)
elif type(value) is TALESMethod:
value = TALESMethod(value._text)
elif not isinstance(value, (str, unicode, int, long, bool,
list, tuple, dict)):
elif value is not None and not isinstance(value,
(str, unicode, int, long, bool, list, tuple, dict)):
raise ValueError, repr(value)
new_dict[key] = value
return new_dict
......@@ -742,7 +742,7 @@ class ERP5Form(ZMIForm, ZopePageTemplate):
if is_equal(target_field.get_recursive_orig_value(i),
new_values[i]):
del new_values[i]
for i in new_tales:
for i in new_tales.keys():
if not i in target_field.delegated_list:
# obsolete variable check
try:
......
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