Skip to content

Commit 1c778b3

Browse files
committed
Merge pull request #32 from TwoApart/master
Bug fix: Host header bad setted
2 parents be1e2a0 + 06d2da8 commit 1c778b3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/XMLHttpRequest.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -310,7 +310,7 @@ exports.XMLHttpRequest = function() {
310310
var uri = url.pathname + (url.search ? url.search : '');
311311

312312
// Set the Host header or the server may reject the request
313-
headers["Host"] = host;
313+
headers["Host"] = host + ':' + url.port;
314314

315315
// Set Basic Auth if necessary
316316
if (settings.user) {

0 commit comments

Comments
 (0)