Advertisement
Guest User

Untitled

a guest
Jul 23rd, 2014
199
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.42 KB | None | 0 0
  1. // Enable jsonp
  2. app.enable('jsonp callback');
  3.  
  4. // cookieParser should be above session
  5. app.use(express.cookieParser(config.sessionSecret));
  6.  
  7. app.use(express.cookieSession({
  8. secret : config.sessionSecret,
  9. cookie: {
  10. maxAge : 2400000 //1 Hour
  11. }
  12. }));
  13.  
  14. // use passport session
  15. app.use(passport.initialize());
  16. app.use(passport.session());
  17. app.use(app.router);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement