Hash function broken in Node v0.10

I made the same change as in pull request https://github.com/visionmedia/express/pull/1571.

All tests pass with this change in Node v0.8 and Node v0.10.