From 5260d514abe547f0988259af332f4c123b139b9d Mon Sep 17 00:00:00 2001 From: Alexey Kasyanchuk Date: Sat, 4 Jan 2020 14:29:46 +0300 Subject: [PATCH] fix(log): exceptions log handling --- src/background/background.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/background/background.js b/src/background/background.js index 0eb93e2..ebbde1c 100644 --- a/src/background/background.js +++ b/src/background/background.js @@ -126,6 +126,7 @@ if(portative) // handle promise rejections process.on('unhandledRejection', r => logTE('system', 'Rejection:', r)); +process.on('uncaughtException', (err, origin) => logTE('system', 'Exception:', err, 'Origin:', origin)); const gotTheLock = app.requestSingleInstanceLock() if (!gotTheLock) {