0
Fork 0
mirror of https://github.com/verdaccio/verdaccio.git synced 2024-12-16 21:56:25 -05:00

showing expected content type in errors

This commit is contained in:
Alex Kocharin 2013-09-27 12:55:42 +04:00
parent 64a0ab8be7
commit 9f80a0046e

View file

@ -19,7 +19,7 @@ module.exports.media = function media(expect) {
if (req.headers['content-type'] !== expect) {
next(new UError({
status: 415,
msg: 'wrong content-type, we expect '+expect,
msg: 'wrong content-type, expect: '+expect+', got: '+req.headers['content-type'],
}));
} else {
next();