Skip to content

Commit

Permalink
fix: legacy argument parsing is missing an import
Browse files Browse the repository at this point in the history
  • Loading branch information
iloveitaly committed Aug 3, 2023
1 parent f3d87e0 commit 5528923
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions debugger/util/argument_parser.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,12 @@ const {
ArrayPrototypeJoin,
} = primordials;

const {
exitCodes: {
kGenericUserError,
},
} = internalBinding('errors');

function parseBoolean(value) {
return value === 'true' || value === '1' || value === 'yes';
}
Expand Down Expand Up @@ -75,6 +81,9 @@ function parseArguments(argv) {
return {...options, ...legacyArguments};
}

// the legacy `node inspect` options assumed the first argument was the target
// to avoid breaking existing scripts, we maintain this behavior

function processLegacyArgs(args) {
const target = ArrayPrototypeShift(args);
let host = '127.0.0.1';
Expand Down

0 comments on commit 5528923

Please sign in to comment.