diff --git a/markdownlint-cli2.js b/markdownlint-cli2.js index 44c0650..2d6f119 100755 --- a/markdownlint-cli2.js +++ b/markdownlint-cli2.js @@ -243,7 +243,7 @@ const processArgv = (argv) => { const showHelp = (logMessage) => { logMessage(`https://github.com/DavidAnson/markdownlint-cli2 -Syntax: markdownlint-cli2 glob0 [glob1] [...] [globN] [--config file] [--fix] +Syntax: markdownlint-cli2 glob0 [glob1] [...] [globN] [--config file] [--fix] [--help] Glob expressions (from the globby library): - * matches any number of characters, but not / @@ -918,16 +918,14 @@ const main = async (params) => { if (configPath === null) { configPath = arg; return false; - } - if (arg === "--config") { + // eslint-disable-next-line unicorn/prefer-switch + } else if (arg === "--config") { configPath = null; return false; - } - if (arg === "--fix") { + } else if (arg === "--fix") { fixDefault = true; return false; - } - if (arg === '--help') { + } else if (arg === '--help') { shouldShowHelp = true; return false; }