refactor: fix formatting issues
This commit is contained in:
parent
6612e6edf0
commit
4abc30eed1
|
@ -1532,8 +1532,7 @@ App::patch('/v1/account/password')
|
|||
$history = $user->getAttribute('passwordHistory', []);
|
||||
|
||||
foreach ($history as $hash) {
|
||||
if(Auth::passwordVerify($password, $hash, $user->getAttribute('hash'), $user->getAttribute('hashOptions')))
|
||||
{
|
||||
if (Auth::passwordVerify($password, $hash, $user->getAttribute('hash'), $user->getAttribute('hashOptions'))) {
|
||||
throw new Exception(Exception::USER_PASSWORD_RECENTLY_USED, 'The password was recently used', 409);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -811,8 +811,7 @@ App::patch('/v1/users/:userId/password')
|
|||
$history = $user->getAttribute('passwordHistory', []);
|
||||
|
||||
foreach ($history as $hash) {
|
||||
if(Auth::passwordVerify($password, $hash, $user->getAttribute('hash'), $user->getAttribute('hashOptions')))
|
||||
{
|
||||
if (Auth::passwordVerify($password, $hash, $user->getAttribute('hash'), $user->getAttribute('hashOptions'))) {
|
||||
throw new Exception(Exception::USER_PASSWORD_RECENTLY_USED, 'The password was recently used', 409);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue