Skip to content

Commit 8105f4d

Browse files
committed
ldap: Fix dict return when item not exists
1 parent 900fde5 commit 8105f4d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

scripts/hostcfgd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -419,7 +419,7 @@ class AaaCfg(object):
419419
if self.ldap_global == {}:
420420
return False
421421
return self.ldap_global.get('bind_dn', "") and self.ldap_global.get('base_dn', "") and \
422-
self.ldap_global.get('bind_password', "") and 'ldap' in self.authentication['login'] and \
422+
self.ldap_global.get('bind_password', "") and 'ldap' in self.authentication.get('login', "") and \
423423
self.ldap_servers
424424

425425
def pick_src_intf_ipaddrs(self, keys, src_intf):

0 commit comments

Comments
 (0)