mirror of
https://github.com/pterodactyl/panel.git
synced 2024-11-25 18:42:31 +01:00
api(client): fix TwoFactorController
This commit is contained in:
parent
5fe86f164e
commit
5d1568cf84
@ -83,7 +83,7 @@ class TwoFactorController extends ClientApiController
|
||||
* Disables two-factor authentication on an account if the password provided
|
||||
* is valid.
|
||||
*/
|
||||
public function delete(Request $request): JsonResponse
|
||||
public function delete(Request $request): Response
|
||||
{
|
||||
if (!password_verify($request->input('password') ?? '', $request->user()->password)) {
|
||||
throw new BadRequestHttpException('The password provided was not valid.');
|
||||
|
@ -68,7 +68,7 @@ class ExecuteScheduleTest extends ClientApiIntegrationTestCase
|
||||
|
||||
$response->assertStatus(Response::HTTP_BAD_REQUEST);
|
||||
$response->assertJsonPath('errors.0.code', 'BadRequestHttpException');
|
||||
$response->assertJsonPath('errors.0.detail', 'Cannot trigger schedule exection for a schedule that is not currently active.');
|
||||
$response->assertJsonPath('errors.0.detail', 'Cannot trigger schedule exception for a schedule that is not currently active.');
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user