Comparing version 0.0.4 to 0.0.5
@@ -62,5 +62,7 @@ const path = require('path'); | ||
.setupSecuritySettings() | ||
.setupCookieParserMiddleware() | ||
.setupExpressMiddleware() | ||
.setupRequestLogging() | ||
.setupRoutes() | ||
.setupBodyParserMiddleware() | ||
.setupErrorHandling(); | ||
@@ -100,5 +102,11 @@ | ||
this.app.enable('trust proxy'); | ||
this.app.disable('x-powered-by'); | ||
return this; | ||
} | ||
setupBodyParserMiddleware() { | ||
const {bodyParser} = this.settings.app; | ||
const parser = require('body-parser'); | ||
if (bodyParser) { | ||
@@ -113,3 +121,5 @@ Object.keys(bodyParser).forEach(type => { | ||
} | ||
} | ||
setupCookieParserMiddleware() { | ||
const {cookieSecret} = this.settings.app; | ||
@@ -120,6 +130,2 @@ if (cookieSecret) { | ||
} | ||
this.app.disable('x-powered-by'); | ||
return this; | ||
} | ||
@@ -126,0 +132,0 @@ |
{ | ||
"name": "nightframe", | ||
"version": "0.0.4", | ||
"version": "0.0.5", | ||
"description": "A small Node.js web application framework built on top of Express", | ||
@@ -5,0 +5,0 @@ "author": { |
47098
1438