Skip to content

Commit

Permalink
process: call prepareMainThreadExecution in node inspect
Browse files Browse the repository at this point in the history
Since we should treat the node-inspect as third-party
user code.

PR-URL: nodejs#26466
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
  • Loading branch information
joyeecheung committed Mar 13, 2019
1 parent 25fd0ab commit 6ddb7f6
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions lib/internal/main/inspect.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@

// `node inspect ...` or `node debug ...`

const {
prepareMainThreadExecution
} = require('internal/bootstrap/pre_execution');

prepareMainThreadExecution();

if (process.argv[1] === 'debug') {
process.emitWarning(
'`node debug` is deprecated. Please use `node inspect` instead.',
Expand Down

0 comments on commit 6ddb7f6

Please sign in to comment.