Skip to content

Commit

Permalink
fix errorHandler signature
Browse files Browse the repository at this point in the history
introduced by Vitaly in 82bf325
  • Loading branch information
tj committed Nov 13, 2012
1 parent c874341 commit 8262bd3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/middleware/errorHandler.js
Expand Up @@ -42,7 +42,7 @@ var env = process.env.NODE_ENV || 'development';
*/

exports = module.exports = function errorHandler(){
return function errorHandler(err, req, res){
return function errorHandler(err, req, res, next){
if (err.status) res.statusCode = err.status;
if (res.statusCode < 400) res.statusCode = 500;
if ('test' != env) console.error(err.stack);
Expand Down

0 comments on commit 8262bd3

Please sign in to comment.