Commits

Zhang Huangbin committed 8dcc2bf

Fixed: Local variable 'forwarding_addresses_not_in_domain' referenced before assignment in libs/dbmail_mysql/user.py.
Thanks Marko Kobal <marko.kobal _at_ arctur.si> for the report.

Comments (0)

Files changed (2)

ChangeLog.dbmail_mysql

           Thanks Bernhard Roth <broth _at_ roth-itk.de> for helping test.
 
     * Fixed:
+        + Local variable 'forwarding_addresses_not_in_domain' referenced before
+          assignment in libs/dbmail_mysql/user.py.
+          Thanks Marko Kobal <marko.kobal _at_ arctur.si> for the report.
         + Not convert timestamp of admin logs to LOCAL_TIMEZONE.
 
 = 1.1.1 =

libs/dbmail_mysql/user.py

             except Exception, e:
                 return (False, str(e))
 
+            forwarding_addresses_in_domain = []
+            forwarding_addresses_not_in_domain = []
             if len(mailForwardingAddresses) > 0:
                 forwarding_addresses_in_domain = [addr for addr in mailForwardingAddresses if addr.endswith('@' + self.domain)]
                 forwarding_addresses_not_in_domain = [addr for addr in mailForwardingAddresses if not addr.endswith('@' + self.domain)]