From 7c8ac84e422da5a4c4418b6f69094ade5ee4ff1a Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=B4me=20Benoit?= Date: Mon, 14 Aug 2023 21:07:45 +0200 Subject: [PATCH] refactor: cleanup worker catch clause MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Jérôme Benoit --- src/worker/abstract-worker.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/worker/abstract-worker.ts b/src/worker/abstract-worker.ts index 56a7696f..5a61f1cf 100644 --- a/src/worker/abstract-worker.ts +++ b/src/worker/abstract-worker.ts @@ -344,7 +344,7 @@ export abstract class AbstractWorker< // eslint-disable-next-line @typescript-eslint/no-invalid-void-type this.opts.killHandler?.() as void this.sendToMainWorker({ kill: 'success', workerId: this.id }) - } catch (error) { + } catch { this.sendToMainWorker({ kill: 'failure', workerId: this.id }) } finally { this.emitDestroy() -- 2.34.1