From c57c2452bad881fe6db18b5cb722f7a16caa8a10 Mon Sep 17 00:00:00 2001 From: Adhidarma Hadiwinoto <adhisimon@gmail.com> Date: Tue, 22 Feb 2022 10:37:39 +0700 Subject: [PATCH] ESLINT command-group --- lib/command-group.js | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/lib/command-group.js b/lib/command-group.js index 4dcb8d8..89de5cd 100644 --- a/lib/command-group.js +++ b/lib/command-group.js @@ -1,14 +1,13 @@ -"use strict"; - const defaultCommand = require('./default-command'); const commands = { }; -for (let [key, value] of Object.entries(defaultCommand)) { - value.forEach(function(element) { +// eslint-disable-next-line no-restricted-syntax +for (const [key, value] of Object.entries(defaultCommand)) { + value.forEach((element) => { commands[element.toLowerCase()] = key.toLowerCase(); - }) + }); } -module.exports = commands; \ No newline at end of file +module.exports = commands; -- 1.9.0