VirtualMailManager/serviceset.py
branchv0.7.x
changeset 694 b1bfd4d1d9c0
parent 691 932cd76bf879
child 696 45f76850c7e9
--- a/VirtualMailManager/serviceset.py	Sat Feb 09 17:24:12 2013 +0000
+++ b/VirtualMailManager/serviceset.py	Sun Feb 10 17:33:38 2013 +0000
@@ -42,7 +42,7 @@
         arguments ('smtp', 'pop3',  'imap', 'sieve') must be provided.
 
         Arguments:
-        `dbh` : pyPgSQL.PgSQL.Connection or psycopg2.extensions.connection
+        `dbh` : psycopg2.extensions.connection
           A database connection for the database access.
 
         Keyword arguments:
@@ -123,9 +123,7 @@
         if not result:
             raise ValueError('Unknown service_set id specified: %r' % ssid)
         self._ssid = result[0]
-        #self._services.update(zip(SERVICES, result[1:]))
-        for key, value in zip(SERVICES, result[1:]):  # pyPgSQL compatible
-            self._services[key] = True if value else False
+        self._services.update(list(zip(SERVICES, result[1:])))
 
     def _save(self):
         """Store a new service_set in the database."""