diff --git a/apps/advanced/common/models/User.php b/apps/advanced/common/models/User.php index 24752bf..9b8198e 100644 --- a/apps/advanced/common/models/User.php +++ b/apps/advanced/common/models/User.php @@ -101,9 +101,9 @@ class User extends ActiveRecord implements Identity public function beforeSave($insert) { - if(parent::beforeSave($insert)) { - if($this->isNewRecord) { - if(!empty($this->password)) { + if (parent::beforeSave($insert)) { + if ($this->isNewRecord) { + if (!empty($this->password)) { $this->password_hash = SecurityHelper::generatePasswordHash($this->password); } }