Skip to content

Commit

Permalink
Merge pull request #117 from coronasafe/fix-error-handler
Browse files Browse the repository at this point in the history
fix error handler
  • Loading branch information
khavinshankar authored Dec 1, 2023
2 parents cb9e23e + 3ca3aa0 commit 1ca570d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/middleware/errorHandler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ const sendProdError = (err: any, res: Response) => {
});
};

export const errorHandler: ErrorRequestHandler = (err, req, res) => {
export const errorHandler: ErrorRequestHandler = (err, req, res, next) => {
err.statusCode = err.statusCode || 500;
err.status = err.status || "error";

Expand Down

0 comments on commit 1ca570d

Please sign in to comment.