diff --git a/src/middlewares/json-api-express.ts b/src/middlewares/json-api-express.ts index 01a9b89..83eb894 100644 --- a/src/middlewares/json-api-express.ts +++ b/src/middlewares/json-api-express.ts @@ -51,7 +51,7 @@ export default function jsonApiExpress( try { await authenticate(appInstance, req); } catch (error) { - res.status(error.status).json(convertErrorToHttpResponse(error)); + res.status(+error.status).json(convertErrorToHttpResponse(error)); return next(); }