Mashape/unirest-nodejs — pull request #34 by sedouard (2014-12-16 19:03:07+00:00)
Title: Multipart form data requests fail with port number

URL.parse parses the port information however it leaves the ':80' or whatever port number in the host name. FormData chokes on this because it doesn't expect that in the host field.

Added a regex to remove this from the the first occurrence in this in the host field. The port number should always be captured in the host field anyways. Added a unit test to cover this scenario.