diff --git a/src/Ltb/Directory/OpenLDAP.php b/src/Ltb/Directory/OpenLDAP.php index fcd1e9e..64d3dbe 100644 --- a/src/Ltb/Directory/OpenLDAP.php +++ b/src/Ltb/Directory/OpenLDAP.php @@ -224,7 +224,7 @@ public function enableAccount($ldap, $dn) : bool { $attrsToDelete = array( 'pwdAccountDisabled' => array() ); - $update = \Ltb\PhpLDAP::ldap_mod_del($ldap, $dn, $attrsToDelete); + $update = \Ltb\PhpLDAP::ldap_mod_replace($ldap, $dn, $attrsToDelete); $errno = \Ltb\PhpLDAP::ldap_errno($ldap); if ($errno) {