diff --git a/packages/http-error-handler/index.js b/packages/http-error-handler/index.js index 0d7439406..d33c70068 100644 --- a/packages/http-error-handler/index.js +++ b/packages/http-error-handler/index.js @@ -20,13 +20,10 @@ const httpErrorHandlerMiddleware = (opts = {}) => { } // Non-http error OR expose set to false - if ( - options.fallbackMessage && - (!request.error.statusCode || !request.error.expose) - ) { + if (!request.error.expose || !request.error.statusCode) { request.error = { statusCode: 500, - message: options.fallbackMessage, + message: options.fallbackMessage || 'Internal Server Error', expose: true } }