Less crashing, websocket more consistent

This commit is contained in:
bingus_violet 2024-03-18 20:57:48 -05:00
parent 49317e4795
commit 1efd9dc2a7
2 changed files with 24 additions and 5 deletions

View file

@ -31,4 +31,12 @@ if (!fs.existsSync(cachePath)) {
}
}
app.use(pageUpdater.middleWare)
app.use(pageUpdater.middleWare)
process.on('uncaughtException', (err, origin) => {
fs.writeSync(
process.stderr.fd,
`Caught exception: ${err}\n` +
`Exception origin: ${origin}`,
);
});