Skip to content

Commit 8571314

Browse files
committed
Fixed blocker issues reported by sonarqube in js files
All of them are trailing comma in array or object more details @ https://analysis.apache.org/component_issues?id=org.apache.cloudstack%3Acloudstack#resolved=false|severities=BLOCKER|languages=js
1 parent e8f8e0e commit 8571314

10 files changed

Lines changed: 21 additions & 22 deletions

File tree

ui/scripts/accounts.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1531,7 +1531,7 @@
15311531
label: 'label.name',
15321532
validation: {
15331533
required: true
1534-
},
1534+
}
15351535
},
15361536
publickey: {
15371537
label: 'Public Key'
@@ -1587,7 +1587,7 @@
15871587
data: items
15881588
});
15891589
}
1590-
},
1590+
}
15911591
},
15921592
account: {
15931593
label: 'label.account',

ui/scripts/configuration.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2157,7 +2157,7 @@
21572157
label: 'label.disk.iops.write.rate'
21582158
},
21592159
cacheMode: {
2160-
label: 'label.cache.mode',
2160+
label: 'label.cache.mode'
21612161
},
21622162
tags: {
21632163
label: 'label.storage.tags'
@@ -3684,7 +3684,7 @@
36843684

36853685
fields[id.isEnabled] = {
36863686
label: serviceDisplayName,
3687-
isBoolean: true,
3687+
isBoolean: true
36883688
};
36893689

36903690
serviceFields.push(id.isEnabled);
@@ -3734,7 +3734,7 @@
37343734
dependsOn: 'service.SourceNat.isEnabled',
37353735
isBoolean: true
37363736
}
3737-
},//end of fields
3737+
}//end of fields
37383738
}, //end of createForm
37393739

37403740
action: function(args) {

ui/scripts/docs.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -368,7 +368,7 @@ cloudStack.docs = {
368368
externalLink: ''
369369
},
370370
helpDiskOfferingHypervisorSnapshotReserve: {
371-
desc: 'Hypervisor snapshot reserve space as a percent of a volume (for managed storage using XenServer or VMware) (Ex. The value 25 means 25%.)).',
371+
desc: 'Hypervisor snapshot reserve space as a percent of a volume (for managed storage using XenServer or VMware) (Ex. The value 25 means 25%.)).'
372372
},
373373
helpDiskOfferingCacheMode: {
374374
desc: 'The write caching mode to use for disks created with this disk offering. This can improve write performance.',

ui/scripts/network.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -677,7 +677,7 @@
677677
data: null
678678
});
679679
}
680-
},
680+
}
681681
},
682682
account: {
683683
label: 'label.account',

ui/scripts/storage.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -810,7 +810,7 @@
810810
}
811811
},
812812
name: {
813-
label: 'label.name',
813+
label: 'label.name'
814814
}
815815
}
816816
},

ui/scripts/system.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3985,7 +3985,7 @@
39853985
})
39863986
});
39873987
}
3988-
},
3988+
}
39893989
},
39903990
actions: {
39913991
enable: {
@@ -7486,7 +7486,7 @@
74867486
actionFilter: networkProviderActionFilter('GloboDns')
74877487
});
74887488
}
7489-
},
7489+
}
74907490
},
74917491
actions: {
74927492
add: {
@@ -12917,7 +12917,7 @@
1291712917
label: 'label.api.version'
1291812918
},
1291912919
retrycount: {
12920-
label: 'label.numretries',
12920+
label: 'label.numretries'
1292112921
},
1292212922
retryinterval: {
1292312923
label: 'label.retry.interval'
@@ -13073,7 +13073,7 @@
1307313073
label: 'label.api.version'
1307413074
},
1307513075
retrycount: {
13076-
label: 'label.numretries',
13076+
label: 'label.numretries'
1307713077
},
1307813078
retryinterval: {
1307913079
label: 'label.retry.interval'
@@ -15710,7 +15710,7 @@
1571015710
$.extend(data, {
1571115711
agentusername: args.data.agentUsername,
1571215712
agentpassword: args.data.agentPassword,
15713-
agentport: args.data.agentPort,
15713+
agentport: args.data.agentPort
1571415714
});
1571515715
}
1571615716
}
@@ -20286,7 +20286,7 @@
2028620286
var jid = json[apiCmdRes].jobid;
2028720287
args.response.success({
2028820288
_custom: {
20289-
jobId: jid,
20289+
jobId: jid
2029020290
}
2029120291
});
2029220292
}

ui/scripts/templates.js

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -992,7 +992,7 @@
992992

993993
//***** updateTemplatePermissions *****
994994
var data = {
995-
id: args.context.templates[0].id,
995+
id: args.context.templates[0].id
996996
//zoneid: args.context.templates[0].zoneid //can't update template/ISO in only one zone. It always get updated in all zones.
997997
};
998998

@@ -1148,7 +1148,7 @@
11481148
notification: {
11491149
poll: pollAsyncJobResult
11501150
}
1151-
},
1151+
}
11521152

11531153
},
11541154
tabs: {
@@ -1726,8 +1726,7 @@
17261726

17271727
templatetype: {
17281728
label: 'label.type'
1729-
},
1730-
1729+
}
17311730

17321731
}],
17331732

@@ -2134,7 +2133,7 @@
21342133

21352134
//***** updateIsoPermissions *****
21362135
var data = {
2137-
id: args.context.isos[0].id,
2136+
id: args.context.isos[0].id
21382137
//zoneid: args.context.isos[0].zoneid //can't update template/ISO in only one zone. It always get updated in all zones.
21392138
};
21402139
//if args.data.ispublic is undefined(i.e. checkbox is hidden), do not pass ispublic to API call.

ui/scripts/ui-custom/instanceWizard.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -407,7 +407,7 @@
407407
['featuredisos', 'instance-wizard-featured-isos'],
408408
['communityisos', 'instance-wizard-community-isos'],
409409
['myisos', 'instance-wizard-my-isos'],
410-
['sharedisos', 'instance-wizard-shared-isos'],
410+
['sharedisos', 'instance-wizard-shared-isos']
411411
//['isos', 'instance-wizard-all-isos']
412412
]
413413
).each(function() {

ui/scripts/ui-custom/login.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@
142142
},
143143
error: function(xhr) {
144144
$login.find('#saml-login').hide();
145-
},
145+
}
146146
});
147147

148148
// Select language

ui/scripts/zoneWizard.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -471,7 +471,7 @@
471471
desc: 'message.tooltip.internal.dns.2',
472472
validation: {
473473
ipv4: true
474-
},
474+
}
475475
},
476476
hypervisor: {
477477
label: 'label.hypervisor',

0 commit comments

Comments
 (0)