From 178e52a7ead2ef9ffb6eb5e17be167f17beb45a8 Mon Sep 17 00:00:00 2001 From: Gus Caplan Date: Fri, 12 Jun 2020 16:12:17 -0500 Subject: [PATCH] lib: remove manual exception handling in queueMicrotask PR-URL: https://github.com/nodejs/node/pull/33859 Reviewed-By: Anna Henningsen Reviewed-By: David Carlier Reviewed-By: James M Snell --- lib/internal/process/task_queues.js | 8 -------- 1 file changed, 8 deletions(-) diff --git a/lib/internal/process/task_queues.js b/lib/internal/process/task_queues.js index c07942587ca9c2..3cf07601a23aa4 100644 --- a/lib/internal/process/task_queues.js +++ b/lib/internal/process/task_queues.js @@ -15,10 +15,6 @@ const { enqueueMicrotask } = internalBinding('task_queue'); -const { - triggerUncaughtException -} = internalBinding('errors'); - const { setHasRejectionToWarn, hasRejectionToWarn, @@ -151,10 +147,6 @@ function runMicrotask() { const callback = this.callback; try { callback(); - } catch (error) { - // runInAsyncScope() swallows the error so we need to catch - // it and handle it here. - triggerUncaughtException(error, false /* fromPromise */); } finally { this.emitDestroy(); }