1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2025-01-21 13:00:36 -05:00

Fixing the error in the try catch block

This commit is contained in:
Mohammad Sulaiman 2025-01-12 10:59:13 +02:00
parent 7477d0cdfb
commit 37fa3ce264

View file

@ -299,17 +299,16 @@ class ChildProcess {
try {
const onAbort = () => this.kill("SIGTERM");
signal?.[abortSignal.add](onAbort);
const waitPromise = op_spawn_wait(this.#rid);
this.#waitPromise = waitPromise;
this.#status = PromisePrototypeThen(waitPromise, (res) => {
signal?.[abortSignal.remove](onAbort);
this.#waitComplete = true;
return res;
});
} catch (e) {
void e;
}
const waitPromise = op_spawn_wait(this.#rid);
this.#waitPromise = waitPromise;
this.#status = PromisePrototypeThen(waitPromise, (res) => {
signal?.[abortSignal.remove](onAbort);
this.#waitComplete = true;
return res;
});
}
#status;