[Mpuls-commits] r5994 - base/trunk/mpulsweb/model

scm-commit at wald.intevation.org scm-commit at wald.intevation.org
Mon Jun 25 14:52:38 CEST 2012


Author: bricks
Date: 2012-06-25 14:52:38 +0200 (Mon, 25 Jun 2012)
New Revision: 5994

Modified:
   base/trunk/mpulsweb/model/agencysettings.py
Log:
Also convert NULL values to False

It did confuse me that NULL values have been converted
to u'None' in python. Therefore convert NULL/None also to
False.


Modified: base/trunk/mpulsweb/model/agencysettings.py
===================================================================
--- base/trunk/mpulsweb/model/agencysettings.py	2012-06-25 11:36:26 UTC (rev 5993)
+++ base/trunk/mpulsweb/model/agencysettings.py	2012-06-25 12:52:38 UTC (rev 5994)
@@ -72,7 +72,7 @@
             for row in rows:
                 if row['wert'] == 'on':
                     wert = True
-                elif row['wert'] == 'off':
+                elif row['wert'] == 'off' or row['wert'] is None:
                     wert = False
                 else:
                     wert = ensure_unicode(row['wert'])



More information about the Mpuls-commits mailing list