Fix bad key

This commit is contained in:
Laurent Destailleur 2020-11-13 19:38:44 +01:00
parent b9f1f6d909
commit 283a42c086

View File

@ -3000,7 +3000,8 @@ class User extends CommonObject
$this->office_fax = $ldapuser->{$conf->global->LDAP_FIELD_FAX};
$this->email = $ldapuser->{$conf->global->LDAP_FIELD_MAIL};
foreach ($socialnetworks as $key => $value) {
$this->socialnetworks[$value['label']] = $ldapuser{$conf->global->{'LDAP_FIELD_'.strtoupper($value['label'])}};
$tmpkey = 'LDAP_FIELD_'.strtoupper($value['label']);
$this->socialnetworks[$value['label']] = $ldapuser->{$conf->global->$tmpkey};
}
$this->ldap_sid = $ldapuser->{$conf->global->LDAP_FIELD_SID};