jed/cookies — Issue #5: Usable with http.request()?
Author: ChiperSoft
Created: 2012-01-08 21:44:31+00:00
State: open

Is this class for node servers only? I attempted to use it in conjunction with http.request() and got an error reading from an undefined value.

/Apache/www/api_unit_tests/node_modules/cookies/lib/cookies.js:14
header = this.request.headers[ "cookie" ]

TypeError: Cannot read property 'cookie' of undefined
at Object.get (/Apache/www/api_unit_tests/node_modules/cookies/lib/cookies.js:14:34)
at IncomingMessage. (/Apache/www/api_unit_tests/tests/00007 auth-get-session.js:30:23)
at IncomingMessage.emit (events.js:67:17)
at HTTPParser.onBody (http.js:113:42)
at Socket.ondata (http.js:1124:24)
at TCP.onread (net.js:336:27)

If not, is there another node library that does work for requests?