mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-06-01 15:14:36 -04:00
force status codes to be returned
This commit is contained in:
parent
1f624e28bc
commit
1c2ba3a53e
@ -93,7 +93,7 @@ class LoginController extends BaseController
|
|||||||
if ($this->hasTooManyLoginAttempts($request)) {
|
if ($this->hasTooManyLoginAttempts($request)) {
|
||||||
$this->fireLockoutEvent($request);
|
$this->fireLockoutEvent($request);
|
||||||
|
|
||||||
return response()->json(['message' => 'Too many login attempts, you are being throttled']);
|
return response()->json(['message' => 'Too many login attempts, you are being throttled'], 401);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($this->attemptLogin($request))
|
if ($this->attemptLogin($request))
|
||||||
@ -102,7 +102,7 @@ class LoginController extends BaseController
|
|||||||
|
|
||||||
$this->incrementLoginAttempts($request);
|
$this->incrementLoginAttempts($request);
|
||||||
|
|
||||||
return response()->json(['message' => ctrans('texts.invalid_credentials')]);
|
return response()->json(['message' => ctrans('texts.invalid_credentials')], 401);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user