1 | error = require './error-middleware'
|
2 |
|
3 | module.exports = exec = (f) -> (req, res, next) ->
|
4 | f req, (err, result) ->
|
5 | return exec.errorCallback req, res, err, 'exec' if err?
|
6 | next()
|
7 |
|
8 | module.exports.defaultErrorCallback = error
|
9 | module.exports.errorCallback = error
|