mirror of
https://github.com/smogon/pokemon-showdown.git
synced 2026-09-08 01:05:31 -05:00
Fix bug in previous commit
This commit is contained in:
@@ -28,12 +28,12 @@ class SubprocessStream extends Streams.ObjectReadWriteStream {
|
||||
this.process.send(`${taskId}\nNEW`);
|
||||
}
|
||||
_write(/** @type {string} */ message) {
|
||||
if (!process.connected) return;
|
||||
if (!this.process.connected) return;
|
||||
this.process.send(`${this.taskId}\nWRITE\n${message}`);
|
||||
// responses are handled in ProcessWrapper
|
||||
}
|
||||
_destroy() {
|
||||
if (!process.connected) return;
|
||||
if (!this.process.connected) return;
|
||||
this.process.send(`${this.taskId}\nDESTROY`);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user