From af9e6e13da42ca8d9c967782392f5705930da14d Mon Sep 17 00:00:00 2001 From: Bubka <858858+Bubka@users.noreply.github.com> Date: Wed, 5 Feb 2020 17:17:25 +0100 Subject: [PATCH] Replace TOTP with OTP in locales for more generic error messages --- app/Http/Controllers/QrCodeController.php | 2 +- resources/js/views/twofaccounts/Create.vue | 2 +- resources/lang/en/errors.php | 2 +- resources/lang/en/twofaccounts.php | 2 +- resources/lang/en/validation.php | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/app/Http/Controllers/QrCodeController.php b/app/Http/Controllers/QrCodeController.php index 5750b8f6..63f9475d 100644 --- a/app/Http/Controllers/QrCodeController.php +++ b/app/Http/Controllers/QrCodeController.php @@ -60,7 +60,7 @@ public function decode(Request $request) catch (AssertionFailedException $exception) { $error = \Illuminate\Validation\ValidationException::withMessages([ - 'qrcode' => __('errors.response.no_valid_totp') + 'qrcode' => __('errors.response.no_valid_otp') ]); throw $error; diff --git a/resources/js/views/twofaccounts/Create.vue b/resources/js/views/twofaccounts/Create.vue index 0d6901a6..5c6f6644 100644 --- a/resources/js/views/twofaccounts/Create.vue +++ b/resources/js/views/twofaccounts/Create.vue @@ -61,7 +61,7 @@
- +
diff --git a/resources/lang/en/errors.php b/resources/lang/en/errors.php index ccfef3e2..95ba2d5d 100644 --- a/resources/lang/en/errors.php +++ b/resources/lang/en/errors.php @@ -20,7 +20,7 @@ 'refresh' => 'refresh', 'please' => 'Please ', 'response' => [ - 'no_valid_totp' => 'No valid TOTP resource in this QR code', + 'no_valid_otp' => 'No valid OTP resource in this QR code', ], 'something_wrong_with_server' => 'Something is wrong with your server', 'Unable_to_decrypt_uri' => 'Unable to decrypt uri', diff --git a/resources/lang/en/twofaccounts.php b/resources/lang/en/twofaccounts.php index 8ae46f9c..65c553a6 100644 --- a/resources/lang/en/twofaccounts.php +++ b/resources/lang/en/twofaccounts.php @@ -32,7 +32,7 @@ ], 'new_account' => 'New account', 'edit_account' => 'Edit account', - 'totp_uri' => 'TOTP Uri', + 'otp_uri' => 'OTP Uri', 'hotp_counter' => 'HOTP Counter', 'use_qrcode' => [ 'val' => 'Use a qrcode', diff --git a/resources/lang/en/validation.php b/resources/lang/en/validation.php index ae4ecdc1..35692e3c 100644 --- a/resources/lang/en/validation.php +++ b/resources/lang/en/validation.php @@ -139,7 +139,7 @@ 'image' => 'Supported format are jpeg, png, bmp, gif, svg, or webp', ], 'uri' => [ - 'starts_with' => 'Only valid TOTP uri are supported', + 'starts_with' => 'Only valid OTP uri are supported', ], 'email' => [ 'exists' => 'No account found using this email',