mirror of
https://github.com/strapi/strapi.git
synced 2025-09-19 13:31:34 +00:00
Fix #2444: avoid duplicating the message when wrapping errors with Bom
This commit is contained in:
parent
093178462d
commit
ab5b80e934
@ -37,7 +37,7 @@ module.exports = strapi => {
|
||||
ctx.status = error.status || 500;
|
||||
ctx.body = _.get(ctx.body, 'isBoom')
|
||||
? ctx.body || error && error.message
|
||||
: Boom.wrap(error, ctx.status, ctx.body || error.message);
|
||||
: Boom.wrap(error, ctx.status);
|
||||
}
|
||||
|
||||
if (ctx.response.headers.location) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user