summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2013-05-16 19:47:50 +0200
committerJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2013-05-16 19:47:50 +0200
commit9877c353bb00d9a1eeae7bafe51c727836a0d921 (patch)
treed1caf90972b37d749894ba0eae2a7242175b967e
parent4e8e861f36982644397f67e0f08f62cb3e63623d (diff)
downloadpykolab-9877c353bb00d9a1eeae7bafe51c727836a0d921.tar.gz
Return if the entry result attribute is empty or does not exist
-rw-r--r--pykolab/auth/ldap/__init__.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/pykolab/auth/ldap/__init__.py b/pykolab/auth/ldap/__init__.py
index b168262..93cfc19 100644
--- a/pykolab/auth/ldap/__init__.py
+++ b/pykolab/auth/ldap/__init__.py
@@ -1397,6 +1397,9 @@ class LDAP(pykolab.base.Base):
entry[key] = entry_changes[key]
self.set_entry_attribute(entry, key, entry[key])
+ if not entry.has_key(result_attribute) or entry[result_attribute] == None:
+ return
+
cache.get_entry(self.domain, entry)
self.imap.connect(domain=self.domain)