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.

Backport-PR-URL: nodejs#26662
PR-URL: nodejs#26466
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
  • Loading branch information
joyeecheung authored and targos committed Mar 27, 2019
1 parent df55731 commit 03dba72
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 03dba72

Please sign in to comment.