Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Switch to cookiesession

MemoryStore leaks memory, and is disabled for production use by nodejitsu.
  • Loading branch information...
commit 6d984be022bb15b3b84ed3e6c85eaab4ed951bff 1 parent 4ffb2b9
@joeybaker joeybaker authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 flatiron-passport.js
View
4 flatiron-passport.js
@@ -15,8 +15,8 @@ exports.attach = function(options) {
options.secret = options.secret || 'keyboard cat';
// Add session support.
- app.http.before.push(connect.cookieParser(options.secret));
- app.http.before.push(connect.session());
+ app.http.before.push(connect.cookieParser());
+ app.http.before.push(connect.cookieSession({secret: options.secret, maxAge: 1000 * 60 * 60 * 24 * 30})); //default to 1 month
}
// Initialize passport.
Please sign in to comment.
Something went wrong with that request. Please try again.