adding undefined checks to prevent sending "undefined" in the headers.
Writing the previous submission in a more coffeescript way
Merge pull request #13 from cbupp/master

Sending "authorization":"undefined" causes basic authentication modules to return a 400 instead of 401.