Skip to content

Commit

Permalink
Merge pull request #76 from jtemplej/compatible-with-ie
Browse files Browse the repository at this point in the history
compatible with IE
  • Loading branch information
duskload authored Mar 3, 2020
2 parents a3a0056 + 48904e0 commit 27e1b83
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/components/helpers/get-ua-data.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,6 @@ export const getNavigatorInstance = () => {
export const isIOS13Check = type => {
const nav = getNavigatorInstance();
return (
nav && (nav.platform.includes(type) || (nav.platform === 'MacIntel' && nav.maxTouchPoints > 1 && !window.MSStream))
nav && (nav.platform.indexOf(type) !== -1 || (nav.platform === 'MacIntel' && nav.maxTouchPoints > 1 && !window.MSStream))
);
};
2 changes: 1 addition & 1 deletion src/components/helpers/selectors.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ const isElectronType = () => {
const nav = getNavigatorInstance();
const ua = nav && nav.userAgent.toLowerCase();

return typeof ua === 'string' ? ua.includes('electron') : false;
return typeof ua === 'string' ? /electron/.test(ua) : false;
};

const getIOS13 = () => {
Expand Down

0 comments on commit 27e1b83

Please sign in to comment.