mirror of
https://github.com/snipe/snipe-it.git
synced 2024-12-23 12:44:12 -08:00
Possible fix for #5054 - OpenLDAP (non-AD) LDAP users being deactivated
This commit is contained in:
parent
0b8d70c7ec
commit
5b8cbe29e1
|
@ -169,6 +169,11 @@ class LdapSync extends Command
|
|||
$item['activated'] = ( in_array($results[$i]['useraccountcontrol'][0], $enabled_accounts) ) ? 1 : 0;
|
||||
} else {
|
||||
$item['activated'] = 0;
|
||||
|
||||
// If there is no activated flag, assume this is handled via the OU and activate the users
|
||||
if (empty($ldap_result_active_flag)) {
|
||||
$item['activated'] = 1;
|
||||
}
|
||||
}
|
||||
|
||||
// User exists
|
||||
|
|
Loading…
Reference in a new issue