move middleware.locals only where it is needed and transform it into a common function, simplify translations and adds automatic language detection

This commit is contained in:
Matteo Pagliazzi
2013-11-12 14:49:01 +01:00
parent b6adc8e1d8
commit 1d9148eebb
5 changed files with 33 additions and 31 deletions
-1
View File
@@ -94,7 +94,6 @@ app.use(express.cookieParser());
app.use(express.cookieSession({ secret: nconf.get('SESSION_SECRET'), httpOnly: false, cookie: { maxAge: TWO_WEEKS }}));
//app.use(express.session());
app.use(middleware.splash);
app.use(middleware.locals);
// Initialize Passport! Also use passport.session() middleware, to support
// persistent login sessions (recommended).