senchalabs/connect — pull request #524 by nateps (2012-04-03 02:51:52+00:00)
Title: Fix bug in compress detecting content-type set via writeHead

The compress middleware (and presumably other middleware that respond to the 'header' event) did not properly detect headers set via writeHead. Updates the writeHead patch to use setHeader to set any headers before emitting this event.

For reference to Node's handling of setHeader arguments, see: https://github.com/joyent/node/blob/master/lib/http.js#L911