Skip to content

Commit

Permalink
Use ldap_realname_from_username()
Browse files Browse the repository at this point in the history
Since we already know the username, we can avoid calling the id-based
ldap_realname() wrapper.
  • Loading branch information
dregad committed Jan 24, 2020
1 parent 2ed3e3e commit 28336ef
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/ldap_api.php
Expand Up @@ -396,7 +396,7 @@ function ldap_authenticate_by_username( $p_username, $p_password ) {
$t_fields_to_update = array('password' => md5( $p_password ));

if( ON == config_get( 'use_ldap_realname' ) ) {
$t_fields_to_update['realname'] = ldap_realname( $t_user_id );
$t_fields_to_update['realname'] = ldap_realname_from_username( $p_username );
}

if( ON == config_get( 'use_ldap_email' ) ) {
Expand Down

0 comments on commit 28336ef

Please sign in to comment.