[pve-devel] [PATCH manager] lxc: don't show an empty ssh-public-key field in summary

Wolfgang Bumiller w.bumiller at proxmox.com
Thu Nov 10 14:53:02 CET 2016


---
 www/manager6/lxc/CreateWizard.js | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/www/manager6/lxc/CreateWizard.js b/www/manager6/lxc/CreateWizard.js
index 46f4e81..7cca69e 100644
--- a/www/manager6/lxc/CreateWizard.js
+++ b/www/manager6/lxc/CreateWizard.js
@@ -268,6 +268,10 @@ Ext.define('PVE.lxc.CreateWizard', {
 				if (key === 'password') { // don't show pw
 				    return;
 				}
+				if (key === 'ssh-public-keys' && !kv['ssh-public-keys'].length) {
+				    // don't show empty public keys
+				    return;
+				}
 				var html = Ext.htmlEncode(Ext.JSON.encode(value));
 				data.push({ key: key, value: value });
 			    });
-- 
2.1.4





More information about the pve-devel mailing list