[pbs-devel] [PATCH proxmox-widget-toolkit] utils: render default value correctly

Matthias Heiserer m.heiserer at proxmox.com
Thu Feb 10 11:16:32 CET 2022


Required for corresponding proxmox-backup patch to work correctly.
Otherwise, __default__ is shown when no default-language is set.

Signed-off-by: Matthias Heiserer <m.heiserer at proxmox.com>
---
 src/Utils.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/Utils.js b/src/Utils.js
index 15baac3..d325644 100644
--- a/src/Utils.js
+++ b/src/Utils.js
@@ -90,7 +90,7 @@ utilities: {
     },
 
     render_language: function(value) {
-	if (!value) {
+	if (!value || value === '__default__') {
 	    return Proxmox.Utils.defaultText + ' (English)';
 	}
 	let text = Proxmox.Utils.language_map[value];
-- 
2.30.2






More information about the pbs-devel mailing list