Browse Source

fix: copy http options from opts (not opts.uri)

fix-http-opts
AJ ONeal 2 years ago
committed by GitHub
parent
commit
5b539deb7b
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      index.js

4
index.js

@ -324,7 +324,9 @@ function setDefaults(defs) {
'timeout',
'setHost'
].forEach(function (key) {
finalOpts[key] = opts.uri[key];
if (key in opts) {
finalOpts[key] = opts[key];
}
});
finalOpts.method = opts.method;

Loading…
Cancel
Save