Skip to content
Snippets Groups Projects

Return error when client headers are missing (issue #19)

Closed joel.vonderwe requested to merge jw_issue_timeout into main
1 file
+ 3
1
Compare changes
  • Side-by-side
  • Inline
@@ -38,7 +38,9 @@ class API implements WorkerTask {
@@ -38,7 +38,9 @@ class API implements WorkerTask {
private initBaseMiddlewares() {
private initBaseMiddlewares() {
this.backend.use(multer({
this.backend.use(multer({
limits: { fieldSize: 15 * 1024 * 1024 }
limits: {
 
fieldSize: 15728640 // 15MB
 
}
}).none()); //Used for extract params from body with format "form-data", The none is for say that we do not wait a file in params
}).none()); //Used for extract params from body with format "form-data", The none is for say that we do not wait a file in params
this.backend.use(morganMiddleware); //Log API accesses
this.backend.use(morganMiddleware); //Log API accesses
this.backend.use(helmet()); //Help to secure express, https://helmetjs.github.io/
this.backend.use(helmet()); //Help to secure express, https://helmetjs.github.io/
Loading