Merge branch 'fix/getHeaderName' of Joxit/urequest.js into master
This commit is contained in:
commit
c880788e9a
4
index.js
4
index.js
|
@ -102,8 +102,8 @@ function setDefaults(defs) {
|
||||||
if (!opts.followOriginalHttpMethod) {
|
if (!opts.followOriginalHttpMethod) {
|
||||||
opts.method = 'GET';
|
opts.method = 'GET';
|
||||||
opts.body = null;
|
opts.body = null;
|
||||||
delete opts.headers[getHeaderName(opts.headers, 'Content-Length')];
|
delete opts.headers[getHeaderName(opts, 'Content-Length')];
|
||||||
delete opts.headers[getHeaderName(opts.headers, 'Transfer-Encoding')];
|
delete opts.headers[getHeaderName(opts, 'Transfer-Encoding')];
|
||||||
}
|
}
|
||||||
if (opts.removeRefererHeader && opts.headers) {
|
if (opts.removeRefererHeader && opts.headers) {
|
||||||
delete opts.headers.referer;
|
delete opts.headers.referer;
|
||||||
|
|
Loading…
Reference in New Issue