src/aws/ChangePasswordActiveWindow.php
public function callbackSave($newpass, $newpasswd)
    {
        if (!$this->model || !$this->model instanceof  ChangePasswordInterface) {
            throw new Exception("Unable to find related model object or the model does not implemented the \luya\admin\aws\ChangePasswordInterface.");
        }
        
        if (strlen($newpass) < $this->minCharLength) {
            return $this->sendError(Module::t('aws_changeapssword_minchar', ['min' => $this->minCharLength]));
        }
        
        if ($newpass !== $newpasswd) {
            return $this->sendError(Module::t('aws_changepassword_notequal'));
        }
        
        if ($this->model->changePassword($newpass)) {
            return $this->sendSuccess(Module::t('aws_changepassword_succes'));
        }
        
        $error = current($this->model->getFirstErrors());
        
        return $this->sendError($error);
    }
public function callbackSave($newpass, $newpasswd)
    {
        if (!$this->model || !$this->model instanceof  ChangePasswordInterface) {
            throw new Exception("Unable to find related model object or the model does not implemented the \luya\admin\aws\ChangePasswordInterface.");
        }
        
        if (strlen($newpass) < $this->minCharLength) {
            return $this->sendError(Module::t('aws_changeapssword_minchar', ['min' => $this->minCharLength]));
        }
        
        if ($newpass !== $newpasswd) {
            return $this->sendError(Module::t('aws_changepassword_notequal'));
        }
        
        if ($this->model->changePassword($newpass)) {
            return $this->sendSuccess(Module::t('aws_changepassword_succes'));
        }
        
        $error = current($this->model->getFirstErrors());
        
        return $this->sendError($error);
    }
public function callbackSave ( $ newpass , $ newpasswd ) { if ( ! $ this -> model || ! $ this -> model instanceof ChangePasswordInterface ) { throw new Exception ( "Unable to find related model object or the model does not implemented the \luya\admin\aws\ChangePasswordInterface." ) ; } if ( strlen ( $ newpass ) < $ this -> minCharLength ) { return $ this -> sendError ( Module :: t ( 'aws_changeapssword_minchar' , [ 'min' => $ this -> minCharLength ] ) ) ; } if ( $ newpass !== $ newpasswd ) { return $ this -> sendError ( Module :: t ( 'aws_changepassword_notequal' ) ) ; } if ( $ this -> model -> changePassword ( $ newpass ) ) { return $ this -> sendSuccess ( Module :: t ( 'aws_changepassword_succes' ) ) ; } $ error = current ( $ this -> model -> getFirstErrors ( ) ) ; return $ this -> sendError ( $ error ) ; }
The method which is going to change the password on the current model.

The implementation of this must make sure if the $newPassword and $newPasswordRepetition are equals!

@param string $newpass The new password which must be set.
@param string $newpasswd The repeation in order to check whether does inputs are equal or not.
@return array
@throws \luya\Exception
The method which is going to change the password on the current model .