Comparing version 0.2.8 to 0.2.9
@@ -51,3 +51,3 @@ var http = require("http"), | ||
this.userAgent = "FetchStream"; | ||
this.userAgent = options.userAgent || "FetchStream"; | ||
@@ -138,3 +138,3 @@ this._redirect_count = 0; | ||
urloptions = { | ||
host: urlparts.hostname, | ||
host: urlparts.hostname || urlparts.host, | ||
port: urlparts.port, | ||
@@ -248,4 +248,2 @@ path: urlparts.pathname + (urlparts.search || "") || "/", | ||
url_data.urloptions.agent = this.options.agent; | ||
if (this.options.asyncDnsLoookup) { | ||
@@ -258,5 +256,5 @@ var dnsCallback = (function (err, adresses){ | ||
url_data.urloptions.headers['host'] = url_data.urloptions.hostname+url_data.urloptions.port; | ||
url_data.urloptions.headers['host'] = url_data.urloptions.hostname || url_data.urloptions.host; | ||
url_data.urloptions.hostname = adresses[0]; | ||
url_data.urloptions.host=url_data.urloptions.hostname + (url_data.urloptions.port? ':' + url_data.urloptions.port: ''); | ||
url_data.urloptions.host = url_data.urloptions.headers['host'] + (url_data.urloptions.port? ':' + url_data.urloptions.port: ''); | ||
@@ -263,0 +261,0 @@ this._runStream(url_data, url); |
{ | ||
"name": "fetch", | ||
"description": "Fetch URL contents", | ||
"version": "0.2.8", | ||
"version": "0.2.9", | ||
"author": "Andris Reinman", | ||
@@ -6,0 +6,0 @@ "maintainers": [ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Non-existent author
Supply chain riskThe package was published by an npm account that no longer exists.
Found 1 instance in 1 package
25901
9
0
561