mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-03-06 12:31:33 +01:00
fix: winston showing json object
This commit is contained in:
@@ -53,7 +53,7 @@ exports.handleErrors = function handleErrors(err, req, res, next) { // eslint-di
|
|||||||
return res.locals.isAPI ? res.set('X-Redirect', err.path).status(200).json(err.path) : res.redirect(nconf.get('relative_path') + err.path);
|
return res.locals.isAPI ? res.set('X-Redirect', err.path).status(200).json(err.path) : res.redirect(nconf.get('relative_path') + err.path);
|
||||||
}
|
}
|
||||||
|
|
||||||
winston.error(req.path + '\n', err);
|
winston.error(req.path + '\n' + err.stack);
|
||||||
|
|
||||||
res.status(status || 500);
|
res.status(status || 500);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user