[feature] Rewrite error handler

This commit is contained in:
Usman Kupalov
2023-09-22 11:51:06 +05:00
parent c1d4f50eb5
commit 6f0e7882b5

View File

@ -388,7 +388,8 @@ docsCoServer.install(server, () => {
});
});
app.use((err, req, res, next) => {
let ctx = new operationContext.Context()
let ctx = new operationContext.Context();
ctx.initFromRequest(req);
ctx.logger.error(err.stack);
res.sendStatus(500);
});