From 555aac9c626bfe2dc44e14ef0cdd6c4ce7e1e2b1 Mon Sep 17 00:00:00 2001 From: Joel Alejandro Villarreal Bertoldi Date: Tue, 12 Dec 2023 18:10:06 -0300 Subject: [PATCH] Update src/middlewares/json-api-express.ts --- src/middlewares/json-api-express.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/middlewares/json-api-express.ts b/src/middlewares/json-api-express.ts index 83eb894..fccdae8 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(Number(error.status)).json(convertErrorToHttpResponse(error)); return next(); }