diff --git a/backend/src/controllers/documentation.ts b/backend/src/controllers/documentation.ts index 079e6635..742e15bb 100644 --- a/backend/src/controllers/documentation.ts +++ b/backend/src/controllers/documentation.ts @@ -40,8 +40,8 @@ options.swaggerDefinition.openapi = '3.0.0' const specs: any = swaggerJsdoc(options); // publish swagger json (optional) -router.get(`/bulk.json`, (_, res) => res.send(specs)); -router.get(`/tsoa.json`, (_, res) => res.send(swaggerDocument)); +router.get(`/bulk.json`, (_, res: any) => res.send(specs)); +router.get(`/tsoa.json`, (_, res: any) => res.send(swaggerDocument)); specs.paths = {...specs.paths, ...swaggerDocument.paths} specs.components = {...specs.components, ...swaggerDocument.components} @@ -49,6 +49,6 @@ specs.components = {...specs.components, ...swaggerDocument.components} // deafult swagger-example.json replaced by local swagger file // this could also be done using a res.redirect('/path/to/swagger`) -router.get(`/svelte/swagger-example.json`, (_, res) => res.send(specs)); +router.get(`/svelte/swagger-example.json`, (_, res: any) => res.send(specs)); router.use(`/svelte`, express.static(getCwd(), { 'index': ['index.html'] })); router.use(`/`, swaggerUi.serve, swaggerUi.setup(specs)); diff --git a/backend/src/server.ts b/backend/src/server.ts index ef14a5b0..5f41e174 100644 --- a/backend/src/server.ts +++ b/backend/src/server.ts @@ -93,7 +93,7 @@ app.use(( req: ExRequest, res: ExResponse, next: NextFunction -): ExResponse | void => { +): any => { if (err instanceof ValidateError) { log({ error: "Validation Failed",