Commits

Ralph Bean  committed 6205214

Don't set values if they're unspecified. Let validators stop progress otherwise.

  • Participants
  • Parent commits 41f026e

Comments (0)

Files changed (2)

 
 setup(
     name='tw2.sqla',
-    version='2.0a8',
+    version='2.0a9',
     description='SQLAlchemy database layer for ToscaWidgets 2',
     author='Paul Johnston',
     author_email='paj@pajhome.org.uk',

File tw2/sqla/utils.py

                 protect_prm_tamp=protect_prm_tamp
             )
         elif key not in pk_props:
-            setattr(obj, key, value)
+            if value or type(value) == bool:
+                # Ignore None and '', but we do want to explicitly
+                # set 'False' if its a boolean.
+                setattr(obj, key, value)
+            else:
+                pass
     return obj