Skip to content

Commit

Permalink
fix: πŸ› xml, sync way
Browse files Browse the repository at this point in the history
  • Loading branch information
hzz780 committed Jun 21, 2024
1 parent 68df7d1 commit 1838db3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/util/httpProvider.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ if (process.env.RUNTIME_ENV === 'browser') {
} else {
// For node use xmlhttprequest
// eslint-disable-next-line global-require
RequestLibrary = require('xmlhttprequest').XMLHttpRequest;
RequestLibraryXMLOnly = require('xmlhttprequest').XMLHttpRequest;
// eslint-disable-next-line global-require
RequestLibrary = require('node-fetch');
isFetch = true;
Expand Down Expand Up @@ -210,7 +210,7 @@ export default class HttpProvider {
}

sendAsyncByXMLHttp(requestConfig) {
const request = new RequestLibrary();
const request = RequestLibraryXMLOnly ? new RequestLibraryXMLOnly() : new RequestLibrary();
request.withCredentials = false;
request.timeout = this.timeout;
this.requestSend(requestConfig, request, true);
Expand Down

0 comments on commit 1838db3

Please sign in to comment.