input('current_password'), $this->user()->password)) { throw new InvalidPasswordProvidedException(trans('validation.internal.invalid_password')); } return true; } /** * @return array */ public function rules(): array { $rules = User::getRulesForUpdate($this->user()); return [ 'password' => array_merge($rules['password'], ['confirmed']), 'new_password' => 'required|string', ]; } }