1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/dotclear2_ynh.git synced 2024-09-03 18:26:29 +02:00

Fix first/last name and update at login

This commit is contained in:
Kay0u 2020-04-18 00:36:39 +02:00
parent a4b2910d5d
commit b621a399b8
No known key found for this signature in database
GPG key ID: AE1DCADB6415A156

View file

@ -35,6 +35,13 @@ class ldapDcAuth extends dcAuth
# Store the password # Store the password
$cur->user_pwd = $pwd; $cur->user_pwd = $pwd;
# Store informations about the user
$cur->user_id = $user_id;
$cur->user_email = $info[0]['mail'][0];
$cur->user_name = $info[0]['sn'][0];
$cur->user_firstname = $info[0]['givenname'][0];
$cur->user_displayname = $info[0]['cn'][0];
# If the user exist, then we just update his password. # If the user exist, then we just update his password.
if ($this->core->userExists($user_id)) if ($this->core->userExists($user_id))
{ {
@ -46,10 +53,6 @@ class ldapDcAuth extends dcAuth
# a permission "usage" on the blog "default". # a permission "usage" on the blog "default".
else else
{ {
$cur->user_id = $user_id;
$cur->user_email = $info[0]['mail'][0];
$cur->user_name = $info[0]['givenname'][0];
$cur->user_firstname = $info[0]['sn'][0];
$cur->user_lang = 'fr'; # Can change this, PR are welcome $cur->user_lang = 'fr'; # Can change this, PR are welcome
$cur->user_tz = 'Europe/Paris'; # Can change this, PR are welcome $cur->user_tz = 'Europe/Paris'; # Can change this, PR are welcome
$cur->user_default_blog = 'default'; # Can change this, PR are welcome $cur->user_default_blog = 'default'; # Can change this, PR are welcome