]> BookStack Code Mirror - bookstack/blobdiff - app/Http/Controllers/Auth/MfaBackupCodesController.php
Added testing coverage for tag index
[bookstack] / app / Http / Controllers / Auth / MfaBackupCodesController.php
index c60dbca209d6ef483323a39f2ae7dd3947ab997b..e240900229983e5834f47ddc035517f26dce1396 100644 (file)
@@ -53,6 +53,7 @@ class MfaBackupCodesController extends Controller
 
         if (!auth()->check()) {
             $this->showSuccessNotification(trans('auth.mfa_setup_login_notification'));
+
             return redirect('/login');
         }
 
@@ -72,8 +73,7 @@ class MfaBackupCodesController extends Controller
 
         $this->validate($request, [
             'code' => [
-                'required',
-                'max:12', 'min:8',
+                'required', 'max:12', 'min:8',
                 function ($attribute, $value, $fail) use ($codeService, $codes) {
                     if (!$codeService->inputCodeExistsInSet($value, $codes)) {
                         $fail(trans('validation.backup_codes'));