Update cluster shim for Bun (again)
This commit is contained in:
parent
756d66c654
commit
c3fee277ec
1 changed files with 1 additions and 1 deletions
|
@ -90,7 +90,7 @@ if (!process.singleThreaded) {
|
||||||
const child_process = require("child_process");
|
const child_process = require("child_process");
|
||||||
let newEnvironment = Object.assign({}, env ? env : process.env);
|
let newEnvironment = Object.assign({}, env ? env : process.env);
|
||||||
newEnvironment.NODE_UNIQUE_ID = cluster._workersCounter;
|
newEnvironment.NODE_UNIQUE_ID = cluster._workersCounter;
|
||||||
let newArguments = Object.assign([], process.argv);
|
let newArguments = [...process.argv];
|
||||||
let command = newArguments.shift();
|
let command = newArguments.shift();
|
||||||
let newWorker = child_process.spawn(command, newArguments, {
|
let newWorker = child_process.spawn(command, newArguments, {
|
||||||
env: newEnvironment,
|
env: newEnvironment,
|
||||||
|
|
Loading…
Reference in a new issue