mirror of
/repos/Prototyper.git
synced 2025-12-30 06:31:32 +01:00
show error when error occurs
This commit is contained in:
parent
8ec03c1490
commit
6d1805df8a
@ -22,7 +22,7 @@ module.exports = function (options, res, next) {
|
||||
if (/Data not found*/.test(err.message)) {
|
||||
res.status(404);
|
||||
}
|
||||
return next(JSON.stringify( err));
|
||||
return next(err);
|
||||
}
|
||||
var contentType = getMimeType(options.ext);
|
||||
res.setHeader('Content-Type', contentType);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user