public function saveChanges()
    {
        if (!empty($this->newPassword)) {
            $this->setPassword($this->newPassword);
        }
        if (!empty($this->new_email)) {
            $this->generateEmailToken();
        }
        $updateActivityName = $this->isAttributeChanged('username');
        if (!$this->save(false)) {
            return false;
        }
        if ($updateActivityName) {
            Activity::updateName($this->id, $this->podiumName, $this->podiumSlug);
        }
        return true;
    }
public function saveChanges()
    {
        if (!empty($this->newPassword)) {
            $this->setPassword($this->newPassword);
        }
        if (!empty($this->new_email)) {
            $this->generateEmailToken();
        }
        $updateActivityName = $this->isAttributeChanged('username');
        if (!$this->save(false)) {
            return false;
        }
        if ($updateActivityName) {
            Activity::updateName($this->id, $this->podiumName, $this->podiumSlug);
        }
        return true;
    }
public function saveChanges ( ) { if ( ! empty ( $ this -> newPassword ) ) { $ this -> setPassword ( $ this -> newPassword ) ; } if ( ! empty ( $ this -> new_email ) ) { $ this -> generateEmailToken ( ) ; } $ updateActivityName = $ this -> isAttributeChanged ( 'username' ) ; if ( ! $ this -> save ( false ) ) { return false ; } if ( $ updateActivityName ) { Activity :: updateName ( $ this -> id , $ this -> podiumName , $ this -> podiumSlug ) ; } return true ; }
Saves user account details changes.
@return bool
Saves user account details changes .