diff --git a/lib/framework.js b/lib/framework.js index 0d0a1829..0d14e1f8 100644 --- a/lib/framework.js +++ b/lib/framework.js @@ -269,7 +269,12 @@ class Framework { } // this.addPreprocessor(); - this.setupMiddleware(); + this.setupMiddleware().catch((error) => { + this.logger.log("error", error); + // Can't throw an error here as it won't be caught + // Therefore just killing the process... + process.exit(1); + }); return this; }