[Checkins] SVN: z3ext.layoutform/trunk/src/z3ext/layoutform/utils.py catch exception

Nikolay Kim fafhrd at datacom.kz
Tue Feb 17 07:42:27 EST 2009


Log message for revision 96640:
  catch exception

Changed:
  U   z3ext.layoutform/trunk/src/z3ext/layoutform/utils.py

-=-
Modified: z3ext.layoutform/trunk/src/z3ext/layoutform/utils.py
===================================================================
--- z3ext.layoutform/trunk/src/z3ext/layoutform/utils.py	2009-02-17 11:40:05 UTC (rev 96639)
+++ z3ext.layoutform/trunk/src/z3ext/layoutform/utils.py	2009-02-17 12:42:27 UTC (rev 96640)
@@ -11,7 +11,7 @@
 # FOR A PARTICULAR PURPOSE.
 #
 ##############################################################################
-""" 
+"""
 
 $Id:  2007-12-12 12:27:02Z fafhrd $
 """
@@ -34,7 +34,12 @@
         except:
             value = object()
 
-        if value != data[name]:
+        try:
+            updated = value != data[name]
+        except TypeError:
+            updated = True
+
+        if updated:
             dm.set(data[name])
             # Record the change using information required later
             changes.setdefault(dm.field.interface, []).append(name)



More information about the Checkins mailing list