Skip to content

Commit 9a414bb

Browse files
fix(adapter): make adapter loading error more clear by using platform-specific adapters explicitly (#5837)
1 parent b3e327d commit 9a414bb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/defaults/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ const defaults = {
3737

3838
transitional: transitionalDefaults,
3939

40-
adapter: ['xhr', 'http'],
40+
adapter: platform.isNode ? 'http' : 'xhr',
4141

4242
transformRequest: [function transformRequest(data, headers) {
4343
const contentType = headers.getContentType() || '';

0 commit comments

Comments
 (0)