From 5d1568cf8445417cf51954ab9f6e353c2feb56d1 Mon Sep 17 00:00:00 2001 From: Matthew Penner Date: Sat, 6 Mar 2021 15:53:45 -0700 Subject: [PATCH] api(client): fix TwoFactorController --- app/Http/Controllers/Api/Client/TwoFactorController.php | 2 +- .../Api/Client/Server/Schedule/ExecuteScheduleTest.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Http/Controllers/Api/Client/TwoFactorController.php b/app/Http/Controllers/Api/Client/TwoFactorController.php index ae74ad8be..bc5533921 100644 --- a/app/Http/Controllers/Api/Client/TwoFactorController.php +++ b/app/Http/Controllers/Api/Client/TwoFactorController.php @@ -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.'); diff --git a/tests/Integration/Api/Client/Server/Schedule/ExecuteScheduleTest.php b/tests/Integration/Api/Client/Server/Schedule/ExecuteScheduleTest.php index 7c9d34d18..21e1daa8e 100644 --- a/tests/Integration/Api/Client/Server/Schedule/ExecuteScheduleTest.php +++ b/tests/Integration/Api/Client/Server/Schedule/ExecuteScheduleTest.php @@ -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.'); } /**