mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-07-28 18:23:35 +00:00
chore(cloudcmd) lint: convert forEach to for-of
This commit is contained in:
parent
6d69cd3a48
commit
fd6d384ba2
9 changed files with 25 additions and 24 deletions
|
|
@ -62,7 +62,7 @@ module.exports = (params) => {
|
|||
|
||||
checkPlugins(plugins);
|
||||
|
||||
keys.forEach((name) => {
|
||||
for (const name of keys) {
|
||||
let value = options[name];
|
||||
|
||||
if (/root/.test(name))
|
||||
|
|
@ -75,7 +75,7 @@ module.exports = (params) => {
|
|||
value = prefixer(value);
|
||||
|
||||
config(name, value);
|
||||
});
|
||||
}
|
||||
|
||||
config('console', defaultValue(config, 'console', options));
|
||||
config('configDialog', defaultValue(config, 'configDialog', options));
|
||||
|
|
|
|||
|
|
@ -229,9 +229,9 @@ async function patchConfig(manage, {name, request, response, cache}) {
|
|||
}
|
||||
|
||||
function traverse([manage, json]) {
|
||||
Object.keys(json).forEach((name) => {
|
||||
for (const name of Object.keys(json)) {
|
||||
manage(name, json[name]);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
module.exports._cryptoPass = cryptoPass;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue