Merge pull request #3273 from jumpserver/v52_ldap

[Bugfix] 修复 LDAP 用户导入会重复显示的问题(场景:AD 用户在多个 OU 下面)
pull/3274/head
BaiJiangJie 5 years ago committed by GitHub
commit a6d87f6de4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -93,6 +93,8 @@ class LDAPUtil:
user_item = self._ldap_entry_to_user_item(entry)
user = self.get_user_by_username(user_item['username'])
user_item['existing'] = bool(user)
if user_item in user_items:
continue
user_items.append(user_item)
return user_items

Loading…
Cancel
Save