server/sources/ldapuser.py
branchstable
changeset 4719 aaed3f813ef8
parent 4716 55b6a3262071
child 4913 083b4d454192
--- a/server/sources/ldapuser.py	Fri Feb 26 13:12:01 2010 +0100
+++ b/server/sources/ldapuser.py	Fri Feb 26 13:19:14 2010 +0100
@@ -210,11 +210,11 @@
                 if res:
                     ldapemailaddr = res[0].get(ldap_emailattr)
                     if ldapemailaddr:
-                        rset = session.execute('EmailAddress X,A WHERE '
+                        rset = session.execute('EmailAddress A WHERE '
                                                'U use_email X, U eid %(u)s',
                                                {'u': eid})
                         ldapemailaddr = unicode(ldapemailaddr)
-                        for emaileid, emailaddr in rset:
+                        for emailaddr, in rset:
                             if emailaddr == ldapemailaddr:
                                 break
                         else: