summaryrefslogtreecommitdiffstats
path: root/pykolab/auth/ldap/__init__.py
diff options
context:
space:
mode:
authorThomas Bruederli <bruederli@kolabsys.com>2014-12-15 12:17:22 +0100
committerThomas Bruederli <bruederli@kolabsys.com>2014-12-15 12:17:22 +0100
commitd5c5678fb346696dd5293bc8669accb057363a17 (patch)
treec0cd01bf8c503eab391abfd92c0f999e4be1414a /pykolab/auth/ldap/__init__.py
parentaf36c305dad7016ef02a64699f78704e8ce638b3 (diff)
downloadpykolab-d5c5678fb346696dd5293bc8669accb057363a17.tar.gz
Fix error due to missing 'domain_name_attribute' variable
Diffstat (limited to 'pykolab/auth/ldap/__init__.py')
-rw-r--r--pykolab/auth/ldap/__init__.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/pykolab/auth/ldap/__init__.py b/pykolab/auth/ldap/__init__.py
index e6f43b3..33f3f8e 100644
--- a/pykolab/auth/ldap/__init__.py
+++ b/pykolab/auth/ldap/__init__.py
@@ -2168,6 +2168,10 @@ class LDAP(pykolab.base.Base):
return _domain_attrs[domain_rootdn_attribute]
else:
+ domain_name_attribute = self.config_get('domain_name_attribute')
+ if domain_name_attribute == None:
+ domain_name_attribute = 'associateddomain'
+
if isinstance(_domain_attrs[domain_name_attribute], list):
domain = _domain_attrs[domain_name_attribute][0]
else: