【发布时间】:2014-10-29 13:50:53
【问题描述】:
http://expressjs.com/guide/error-handling.html
function logErrors(err, req, res, next) {
console.error(err.stack);
next(err);
}
此代码在 expressJS 文档中。我想知道下一个(错误)具体会导致什么。我知道这是一个回调函数,你传入了err,但是出错后会调用什么函数呢?
【问题讨论】:
-
它将它传递给下一个中间件。