From e5cdf28e34ee32eba200366bfa3112cdba8eafc7 Mon Sep 17 00:00:00 2001 From: Chris Troutner Date: Thu, 20 Feb 2025 19:03:45 -0700 Subject: [PATCH] Catching and reporting AbortError race condition --- index.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/index.js b/index.js index 350d91e..8681794 100644 --- a/index.js +++ b/index.js @@ -1,4 +1,8 @@ import Server from './bin/server.js' const server = new Server() +process.on('unhandledRejection', (reason, promise) => { + console.log(`Handling ${reason.code} error. stack: `, reason) +}) + server.startServer()