fixed body parser warning

This commit is contained in:
Sahat Yalkabov
2014-07-02 01:12:11 -04:00
parent bb15c457e4
commit 738713fe02

4
app.js
View File

@ -76,7 +76,7 @@ app.use(connectAssets({
}));
app.use(logger('dev'));
app.use(bodyParser.json());
app.use(bodyParser.urlencoded());
app.use(bodyParser.urlencoded({ extended: true }));
app.use(expressValidator());
app.use(methodOverride());
app.use(cookieParser());
@ -103,7 +103,7 @@ app.use(function(req, res, next) {
app.use(function(req, res, next) {
// Remember original destination before login.
var path = req.path.split('/')[1];
if (/auth|login|logout|signup|img|fonts|favicon/i.test(path)) {
if (/auth|login|logout|signup|fonts|favicon/i.test(path)) {
return next();
}
req.session.returnTo = req.path;