Skip to content

Commit

Permalink
Be more lenient detecting window.fetch, to support polyfills. Fixes l…
Browse files Browse the repository at this point in the history
  • Loading branch information
lincolnthree committed May 26, 2020
1 parent f82723c commit 67b9573
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/utils/isIndexedDBValid.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,7 @@ function isIndexedDBValid() {
!/Chrome/.test(navigator.userAgent) &&
!/BlackBerry/.test(navigator.platform);

var hasFetch =
typeof fetch === 'function' &&
fetch.toString().indexOf('[native code') !== -1;
var hasFetch = typeof fetch === 'function';

// Safari <10.1 does not meet our requirements for IDB support
// (see: https://github.com/pouchdb/pouchdb/issues/5572).
Expand Down

0 comments on commit 67b9573

Please sign in to comment.