Skip to content

Commit 0228b9e

Browse files
authored
revert if statement
1 parent 2d686df commit 0228b9e

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/client.js

+5-1
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,11 @@ exports.Request = Request;
6060
*/
6161

6262
request.getXHR = () => {
63-
if (root.XMLHttpRequest) {
63+
if (
64+
root.XMLHttpRequest &&
65+
(!root.location ||
66+
root.location.protocol !== 'file:')
67+
) {
6468
return new XMLHttpRequest();
6569
}
6670

0 commit comments

Comments
 (0)