mirror of
https://github.com/valitydev/salt.git
synced 2024-11-07 00:55:19 +00:00
Remove trailing whitespaces
Remove trailing whitespaces, change line 345 from 'if' to 'elif'
This commit is contained in:
parent
32f906b020
commit
b5b2e7e097
@ -341,14 +341,14 @@ def groups(username, **kwargs):
|
||||
if 'cn' in entry:
|
||||
group_list.append(entry['cn'][0])
|
||||
log.debug('User {0} is a member of groups: {1}'.format(username, group_list))
|
||||
|
||||
if _config('freeipa'):
|
||||
|
||||
elif _config('freeipa'):
|
||||
escaped_username = ldap.filter.escape_filter_chars(username)
|
||||
search_base = _config('group_basedn')
|
||||
search_string = _render_template(_config('group_filter'), escaped_username)
|
||||
search_results = bind.search_s(search_base,
|
||||
ldap.SCOPE_SUBTREE,
|
||||
search_string,
|
||||
search_results = bind.search_s(search_base,
|
||||
ldap.SCOPE_SUBTREE,
|
||||
search_string,
|
||||
[_config('accountattributename'), 'cn'])
|
||||
|
||||
for entry, result in search_results:
|
||||
|
Loading…
Reference in New Issue
Block a user