Comparing version 2.28.0 to 2.29.0
@@ -312,3 +312,3 @@ /*global JSON, setTimeout, setImmediate*/ | ||
rejectUnauthorized = typeof options.rejectUnauthorized !== 'undefined' ? options.rejectUnauthorized : this.rejectUnauthorized, | ||
headers = _.extend({}, this.headers, options.headers), | ||
headers = {}, | ||
// Gotcha: A query specified as a string overrides this.query | ||
@@ -320,5 +320,11 @@ query = typeof options.query === 'string' ? options.query : _.extend({}, this.query, options.query), | ||
Object.keys(headers).forEach(function (header) { | ||
if (typeof headers[header] === 'undefined') { | ||
delete headers[header]; | ||
[this.headers, options.headers].forEach(function (headersObj) { | ||
if (headersObj) { | ||
Object.keys(headersObj).forEach(function (headerName) { | ||
var headerValue = headersObj[headerName]; | ||
if (typeof headerValue === 'undefined') { | ||
return; | ||
} | ||
headers[headerName.toLowerCase()] = headerValue; | ||
}); | ||
} | ||
@@ -325,0 +331,0 @@ }); |
{ | ||
"name": "teepee", | ||
"version": "2.28.0", | ||
"version": "2.29.0", | ||
"description": "Generic HTTP client", | ||
@@ -5,0 +5,0 @@ "main": "lib/Teepee.js", |
Sorry, the diff of this file is too big to display
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
129639
2637