From dd037643aa38a582d7535b9228e122ea1bd29894 Mon Sep 17 00:00:00 2001 From: ChomeNS <95471003+ChomeNS@users.noreply.github.com> Date: Sun, 2 Jul 2023 13:45:11 +0700 Subject: [PATCH] catch uncaught --- index.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/index.js b/index.js index 87f99a6..2f432b6 100644 --- a/index.js +++ b/index.js @@ -53,3 +53,7 @@ io.on('connection', (socket) => { socket.on('reset', resetVM) }) + +process.on('uncaughtException', (e) => { + console.log(`Caught an uncaught exception!\n${e.stack}`) +})