Skip to content

Commit c3ef50c

Browse files
committed
revert env change
1 parent 42e12f1 commit c3ef50c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

index.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ module.exports = function(opts) {
1010
// In the parent, set the tracking environment variable, fork the child and exit
1111
opts = Object.assign({}, {
1212
// spawn options
13-
env: Object.assign({}, process.env, opts && opts.env, {[id]: "1"}),
13+
env: process.env,
1414
cwd: process.cwd(),
1515
stdio: "ignore",
1616
detached: true,
@@ -20,6 +20,7 @@ module.exports = function(opts) {
2020
arguments: process.argv.slice(2),
2121
exitCode: 0,
2222
}, opts);
23+
opts.env = Object.assign({}, opts.env, {[id]: "1"});
2324
require("child_process").spawn(opts.node, [opts.script].concat(opts.arguments), opts).unref();
2425
process.exit(opts.exitCode);
2526
}

0 commit comments

Comments
 (0)