[pbs-devel] [PATCH 2/2] ui: wrap regexText in gettext() for translations

Oguz Bektas o.bektas at proxmox.com
Thu Feb 4 16:32:47 CET 2021


also fix a small typo in recovery keys text

Signed-off-by: Oguz Bektas <o.bektas at proxmox.com>
---
 www/LoginView.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/www/LoginView.js b/www/LoginView.js
index c7f3e857..4b101425 100644
--- a/www/LoginView.js
+++ b/www/LoginView.js
@@ -525,7 +525,7 @@ Ext.define('PBS.login.TfaWindow', {
 			reference: 'totp',
 			allowBlank: false,
 			regex: /^[0-9]{6}$/,
-			regexText: 'TOTP codes consist of six decimal digits',
+			regexText: gettext('TOTP codes consist of six decimal digits'),
 		    },
 		],
 	    },
@@ -552,7 +552,7 @@ Ext.define('PBS.login.TfaWindow', {
 			reference: 'recoveryKey',
 			allowBlank: false,
 			regex: /^[0-9a-f]{4}(-[0-9a-f]{4}){3}$/,
-			regexText: 'Does not looks like a valid recovery key',
+			regexText: gettext('Does not look like a valid recovery key'),
 		    },
 		    {
 			xtype: 'box',
-- 
2.20.1





More information about the pbs-devel mailing list