ui: eslint: No unused or duplicate variables

Signed-off-by: Dominic Jäger <d.jaeger@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
Dominic Jäger 2021-05-18 14:12:14 +02:00 committed by Thomas Lamprecht
parent 46d9a35c33
commit 55ee6ba132
11 changed files with 6 additions and 19 deletions

View File

@ -269,7 +269,6 @@ Ext.define('PVE.lxc.CreateWizard', {
if (key === 'password') { // don't show pw
return;
}
var html = Ext.htmlEncode(Ext.JSON.encode(value));
data.push({ key: key, value: value });
});

View File

@ -99,7 +99,6 @@ Ext.define('PVE.lxc.DNS', {
initComponent: function() {
var me = this;
var i;
var nodename = me.pveSelNode.data.node;
if (!nodename) {
@ -215,8 +214,8 @@ Ext.define('PVE.lxc.DNS', {
var revert_btn = new PVE.button.PendingRevert();
var set_button_status = function() {
var sm = me.getSelectionModel();
var rec = sm.getSelection()[0];
let button_sm = me.getSelectionModel();
let rec = button_sm.getSelection()[0];
if (!rec) {
edit_btn.disable();

View File

@ -6,7 +6,6 @@ Ext.define('PVE.lxc.Options', {
initComponent: function() {
var me = this;
var i;
var nodename = me.pveSelNode.data.node;
if (!nodename) {
@ -163,8 +162,8 @@ Ext.define('PVE.lxc.Options', {
var revert_btn = new PVE.button.PendingRevert();
var set_button_status = function() {
var sm = me.getSelectionModel();
var rec = sm.getSelection()[0];
let button_sm = me.getSelectionModel();
let rec = button_sm.getSelection()[0];
if (!rec) {
edit_btn.disable();

View File

@ -17,7 +17,7 @@ Ext.define('PVE.lxc.RessourceView', {
initComponent: function() {
var me = this;
var i, confid;
let confid;
var nodename = me.pveSelNode.data.node;
if (!nodename) {

View File

@ -157,7 +157,6 @@ Ext.define('PVE.qemu.AgentIPView', {
text = ips.join('<br>');
}
} else if (me.nics && me.nics.error) {
var msg = gettext('Cannot get info from Guest Agent<br>Error: {0}');
text = Ext.String.format(text, me.nics.error.desc);
}
} else if (me.agent) {

View File

@ -375,7 +375,6 @@ Ext.define('PVE.qemu.HDEdit', {
isCreate: me.isCreate,
});
var subject;
if (unused) {
me.subject = gettext('Unused Disk');
} else if (me.isCreate) {

View File

@ -44,8 +44,6 @@ Ext.define('PVE.window.HDMove', {
initComponent: function() {
var me = this;
var diskarray = [];
if (!me.nodename) {
throw "no node name specified";
}

View File

@ -6,7 +6,6 @@ Ext.define('PVE.qemu.Options', {
initComponent: function() {
var me = this;
var i;
var nodename = me.pveSelNode.data.node;
if (!nodename) {
@ -99,7 +98,6 @@ Ext.define('PVE.qemu.Options', {
if (boot.order) {
let list = boot.order.split(';');
let ret = '';
let i = 1;
list.forEach(dev => {
if (ret) {
ret += ', ';
@ -110,7 +108,7 @@ Ext.define('PVE.qemu.Options', {
}
// legacy style and fallback
var i;
let i;
var text = '';
var bootdisk = me.getObjectValue('bootdisk', undefined, pending);
order = boot.legacy || 'cdn';

View File

@ -106,7 +106,6 @@ Ext.define('PVE.qemu.Smbios1Edit', {
me.load({
success: function(response, options) {
var i, confid;
me.vmconfig = response.result.data;
var value = me.vmconfig.smbios1;
if (value) {

View File

@ -93,7 +93,6 @@ Ext.define('PVE.storage.NFSInputPanel', {
setValues: function(values) {
var me = this;
if (values.options) {
var res = values.options;
me.options = values.options.split(',');
me.options.forEach(function(item) {
var match = item.match(/^vers=(.*)$/);

View File

@ -183,8 +183,6 @@ Ext.define('PVE.storage.TemplateView', {
me.content = 'vztmpl';
var sm = me.sm = Ext.create('Ext.selection.RowModel', {});
var reload = function() {
me.store.load();
};