Skip to content

Commit

Permalink
[Style] // Reduce code duplication
Browse files Browse the repository at this point in the history
  • Loading branch information
Dinika committed Dec 4, 2024
1 parent 662a04e commit 09574d7
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions lib/cli/options.js
Original file line number Diff line number Diff line change
Expand Up @@ -143,9 +143,7 @@ const parse = (args = [], defaultValues = {}, ...configObjects) => {
let flag = pair[0];
if (isNodeFlag(flag, false)) {
flag = flag.replace(/^--?/, '');
return arg.includes('=')
? acc.concat([[flag, pair[1]]])
: acc.concat([[flag, true]]);
return acc.concat([[flag, arg.includes('=') ? pair[1] : true]]);
}
return acc;
}, []);
Expand Down

0 comments on commit 09574d7

Please sign in to comment.