Skip to content

Commit

Permalink
Allow setting of withCredentials to false (solves axios#1852)
Browse files Browse the repository at this point in the history
  • Loading branch information
B.J. Rossiter committed Dec 5, 2019
1 parent a17c70c commit 000877c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/adapters/xhr.js
Expand Up @@ -128,9 +128,9 @@ module.exports = function xhrAdapter(config) {
});
}

// Add withCredentials to request if needed
if (config.withCredentials) {
request.withCredentials = true;
// Add withCredentials to request if needed.
if (!utils.isUndefined(config.withCredentials)) {
request.withCredentials = config.withCredentials;
}

// Add responseType to request if needed
Expand Down

0 comments on commit 000877c

Please sign in to comment.