Created
December 16, 2010 19:21
-
-
Save stagas/743840 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| if (secured || !store.cookie.secure) { | |
| // Send an updated cookie to the browser | |
| store.cookie.expires = typeof store.cookie.persistent === 'undefined' || store.cookie.persistent ? new Date(Date.now() + store.maxAge) : null; | |
| // Multiple Set-Cookie headers | |
| headers = headers || {}; | |
| var cookie = utils.serializeCookie(key, req.sessionID, store.cookie); | |
| if (headers['Set-Cookie']) { | |
| headers['Set-Cookie'] += '\r\nSet-Cookie: ' + cookie; | |
| } else { | |
| headers['Set-Cookie'] = cookie; | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment