Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 886527f

Browse files
forivallremy
authored andcommittedMay 1, 2019
fix: disable fork only if string starts with dash
fixes #1554
1 parent 64b474e commit 886527f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed
 

‎lib/monitor/run.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ function run(options) {
9191
const shouldFork =
9292
!config.options.spawn &&
9393
!inBinPath &&
94-
firstArg.indexOf('-') === -1 && // don't fork if there's a node exec arg
94+
!(firstArg.indexOf('-') === 0) && // don't fork if there's a node exec arg
9595
firstArg !== 'inspect' && // don't fork it's `inspect` debugger
9696
executable === 'node' && // only fork if node
9797
utils.version.major > 4 // only fork if node version > 4

0 commit comments

Comments
 (0)
Please sign in to comment.