From 0158885415b05c001f9eeadac719edb92a389637 Mon Sep 17 00:00:00 2001 From: fhenry Date: Thu, 3 Jan 2013 23:57:18 +0100 Subject: [PATCH] CheckStyle I check everypalce where this function is call in Dolibarr, and to be consistant it's better to use new attribute names --- htdocs/user/class/user.class.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/htdocs/user/class/user.class.php b/htdocs/user/class/user.class.php index 175f01da4ea..441186179b3 100644 --- a/htdocs/user/class/user.class.php +++ b/htdocs/user/class/user.class.php @@ -909,14 +909,14 @@ class User extends CommonObject $this->admin = 0; $this->nom = $contact->nom; // TODO deprecated $this->prenom = $contact->prenom; // TODO deprecated - $this->lastname = $contact->nom; - $this->firstname = $contact->prenom; + $this->lastname = $contact->lastname; + $this->firstname = $contact->firstname; $this->email = $contact->email; $this->office_phone = $contact->phone_pro; $this->office_fax = $contact->fax; $this->user_mobile = $contact->phone_mobile; - if (empty($login)) $login=strtolower(substr($contact->prenom, 0, 4)) . strtolower(substr($contact->nom, 0, 4)); + if (empty($login)) $login=strtolower(substr($contact->firstname, 0, 4)) . strtolower(substr($contact->lastname, 0, 4)); $this->login = $login; $this->db->begin();