diff --git a/src/index.ts b/src/index.ts index c80b335..c8f9c70 100644 --- a/src/index.ts +++ b/src/index.ts @@ -89,15 +89,6 @@ app.use(routes); // The error handler must be before any other error middleware and after all controllers app.use(Sentry.Handlers.errorHandler()); -// Optional fallthrough error handler -app.use(function onError(err: Error, req: Request, res: Response, next: NextFunction) { - // The error id is attached to `res.sentry` to be returned - // and optionally displayed to the user for support. - res.statusCode = 500; - // @ts-ignore - res.end(res.sentry + '\n'); -}); - app.listen(config.global.http_port, config.global.http_listen_address, () => { log.web.info(`Listening at http://${config.global.http_listen_address}:${config.global.http_port}`); });