VMM: The pyPgSQL compatibility commit. v0.6.x
authorPascal Volk <user@localhost.localdomain.org>
Sun, 13 Nov 2011 20:19:40 +0000
branchv0.6.x
changeset 482 428ee9cdf1b2
parent 481 90d69ae4f40d
child 483 fb210a116f18
VMM: The pyPgSQL compatibility commit.
VirtualMailManager/serviceset.py
--- a/VirtualMailManager/serviceset.py	Sun Nov 13 20:18:41 2011 +0000
+++ b/VirtualMailManager/serviceset.py	Sun Nov 13 20:19:40 2011 +0000
@@ -129,7 +129,12 @@
         if not result:
             raise ValueError('Unknown service_set id specified: %r' % ssid)
         self._ssid = result[0]
-        self._services.update(zip(SERVICES, result[1:]))
+        #self._services.update(zip(SERVICES, result[1:]))
+        for key, value in zip(SERVICES, result[1:]):  # pyPgSQL compatible
+            if value:
+                self._services[key] = True
+            else:
+                self._services[key] = False
 
     def _save(self):
         """Store a new service_set in the database."""