Skip to content

Commit

Permalink
fix: defensive check on accessing cmd.args
Browse files Browse the repository at this point in the history
  • Loading branch information
remy committed Dec 13, 2017
1 parent fa64cdc commit fd961d6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/monitor/run.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ function run(options) {
if (
// this is a hack to avoid forking if there's a node argument being passed
// it's a short term fix, and I'm not 100% sure that `fork` is the right way
cmd.args[0].indexOf('-') === -1 &&
(cmd.args[0] || '').indexOf('-') === -1 &&
executable === 'node' &&
utils.version.major > 4
) {
Expand Down

0 comments on commit fd961d6

Please sign in to comment.