Handling headers with multiple values correctly.

Selecting only the first header among a list of headers lead to lost cookies.
This made it so the login from the blog admin panel would fail to set cookies.

Now any header with multiple values is joined by the newline character per http standard.
Removing ternary operator for more concise "cast" to Array
Merge pull request #1 from apartmentlist/bug/multi-headers

Handling headers with multiple values correctly.