Fixed cookie lookup (probably a hack)

After the most recent changes and an `npm install`, I couldn't run the examples ([gist](https://gist.github.com/mynnx/8593486)) and my application was running out of memory.

This seemed to fix it.  If others confirm that they have the same problem, I'll look into it a little deeper.