Small change to logging of unhandled rejections

This commit is contained in:
mikiher 2024-09-18 18:44:16 +03:00
parent 942bd0859f
commit d796849d74

View File

@ -182,7 +182,7 @@ class Server {
* @see https://nodejs.org/api/process.html#event-unhandledrejection
*/
process.on('unhandledRejection', async (reason, promise) => {
await Logger.fatal(`[Server] Unhandled rejection: ${reason}, promise:`, util.format('%O', promise))
await Logger.fatal('[Server] Unhandled rejection:', reason, '\npromise:', util.format('%O', promise))
process.exit(1)
})
}