function LdapTestFunctions::drupalLdapUpdateUser in Lightweight Directory Access Protocol (LDAP) 7
Same name and namespace in other branches
- 8.2 ldap_test/LdapTestFunctions.class.php \LdapTestFunctions::drupalLdapUpdateUser()
- 7.2 ldap_test/LdapTestFunctions.class.php \LdapTestFunctions::drupalLdapUpdateUser()
File
- ldap_servers/
tests/ LdapTestFunctions.class.php, line 88 - LdapTestCase.class.php
Class
Code
function drupalLdapUpdateUser($edit = array(), $ldap_authenticated = FALSE, $user) {
if (count($edit)) {
$user = user_save($user, $edit);
}
if ($ldap_authenticated) {
user_set_authmaps($user, array(
'authname_ldap_authentication' => $user->name,
));
}
return $user;
}