...
|
...
|
@@ -87,6 +87,9 @@ app.use(MemcachedSession({ |
|
|
domain: 'yohobuy.com',
|
|
|
httpOnly: false
|
|
|
},
|
|
|
genid() {
|
|
|
return uuid.v4() // use UUIDs for session IDs
|
|
|
},
|
|
|
store: new MemcachedStore({
|
|
|
hosts: config.memcache.session,
|
|
|
prefix: 'yohobuy_session:',
|
...
|
...
|
@@ -122,7 +125,7 @@ app.use((req, res, next) => { |
|
|
|
|
|
if (typeof req.session.reset !== 'function') {
|
|
|
req.session.reset = function() {
|
|
|
req.session = null;
|
|
|
req.session.destroy();
|
|
|
req.session2.reset();
|
|
|
};
|
|
|
}
|
...
|
...
|
|