From 69cf697aa3edb790a2b11a6b80e40f16b16260b4 Mon Sep 17 00:00:00 2001 From: snipe Date: Thu, 20 Jun 2024 15:20:52 +0100 Subject: [PATCH] Added 2fa translation string Signed-off-by: snipe --- app/Http/Middleware/CheckForTwoFactor.php | 2 +- resources/lang/en-US/auth/general.php | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/app/Http/Middleware/CheckForTwoFactor.php b/app/Http/Middleware/CheckForTwoFactor.php index d6e9faa0eb..15e84217e9 100644 --- a/app/Http/Middleware/CheckForTwoFactor.php +++ b/app/Http/Middleware/CheckForTwoFactor.php @@ -49,7 +49,7 @@ class CheckForTwoFactor // Otherwise make sure they're enrolled and show them the 2FA code screen if ((Auth::user()->two_factor_secret != '') && (Auth::user()->two_factor_enrolled == '1')) { - return redirect()->route('two-factor')->with('info', 'Please enter your two-factor authentication code.'); + return redirect()->route('two-factor')->with('info', trans('auth/general.two_factor_code')); } return redirect()->route('two-factor-enroll')->with('success', 'Please enroll a device in two-factor authentication.'); diff --git a/resources/lang/en-US/auth/general.php b/resources/lang/en-US/auth/general.php index e6a6eed0fc..37ac5634d8 100644 --- a/resources/lang/en-US/auth/general.php +++ b/resources/lang/en-US/auth/general.php @@ -14,6 +14,7 @@ return [ 'username_help_bottom' => 'Your username and email address may be the same, but may not be, depending on your configuration. If you cannot remember your username, contact your administrator.

Usernames without an associated email address will not be emailed a password reset link. ', 'google_login' => 'Login with Google Workspace', 'google_login_failed' => 'Google Login failed, please try again.', + 'two_factor_code' => 'Please enter your two-factor authentication code.', ];