|
@@ -22,8 +22,8 @@ |
|
|
block discarded – undo |
|
22
|
22
|
Validator::make($input, [ |
|
23
|
23
|
'current_password' => ['required', 'string'], |
|
24
|
24
|
'password' => $this->passwordRules(), |
|
25
|
|
- ])->after(function ($validator) use ($user, $input) { |
|
26
|
|
- if (! isset($input['current_password']) || ! Hash::check($input['current_password'], $user->password)) { |
|
|
25
|
+ ])->after(function($validator) use ($user, $input) { |
|
|
26
|
+ if (!isset($input['current_password']) || !Hash::check($input['current_password'], $user->password)) { |
|
27
|
27
|
$validator->errors()->add('current_password', __('The provided password does not match your current password.')); |
|
28
|
28
|
} |
|
29
|
29
|
})->validateWithBag('password'); |
Please login to merge, or discard this patch.