Skip to content

Commit

Permalink
Добавили аргумент next в мидлвару
Browse files Browse the repository at this point in the history
  • Loading branch information
Igor Savichev committed Apr 8, 2019
1 parent 49ab401 commit 7231c12
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ app.use(commonData);
routes(app);

// Фиксируем фатальную ошибку и отправляем ответ с кодом 500
app.use((err: Error, _req: Request, res: Response) => {
app.use((err: Error, _req: Request, res: Response, _next: Next) => {
console.error(err.stack);

res.sendStatus(500);
Expand Down

0 comments on commit 7231c12

Please sign in to comment.