workers: minor.
This commit is contained in:
parent
4eb3c2172d
commit
94b5487847
@ -118,8 +118,9 @@ WorkerPool.prototype.spawn = function spawn(id) {
|
||||
|
||||
child.on('exit', (code) => {
|
||||
this.emit('exit', code, child);
|
||||
if (this.children.get(child.id) === child)
|
||||
this.children.delete(child.id);
|
||||
|
||||
if (this.children.get(id) === child)
|
||||
this.children.delete(id);
|
||||
});
|
||||
|
||||
child.on('event', (items) => {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user