Fix small issues with reasonPhrase param in writeHead() proxies #243

Closed
wants to merge 5 commits into
from

Conversation

Projects
None yet
3 participants

orls commented Mar 23, 2011

Hi,

A little thing that tripped me up tonight -- some bits of middleware that didn't work right when trying to use the optional 2nd arg to serverResponse.writeHead().

In logger's case, it would assume it's a header; thus discarding the headers you were trying to set, and not providing useful info in the log output.

Member

tj commented Mar 23, 2011

interesting! I actually never noticed the phrase as a value, never seen it used :D kinda sucks because apply()ing all the time will slow things down a bit

orls commented Mar 23, 2011

It's handy when you need to send a 500 Oh God The Horror response ;-)

I'll rewrite it with straight calls to writeHead() rather than apply -- In logger's case, we need to sniff the params anyway, so not a biggie

Member

tj commented Mar 23, 2011

haha, http is silly. I will merge this right away

Contributor

jonathanong commented Sep 15, 2013

sorry for the delay. do you want to rebase and squash?

Contributor

jonathanong commented Sep 26, 2013

@orls bump

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment