Skip to content

Commit

Permalink
Merge pull request #443 from rory-instil/master
Browse files Browse the repository at this point in the history
Fixing a missing defensive check for an absent window global variable that was breaking service worker environments
  • Loading branch information
martincizek committed Oct 9, 2023
2 parents 97e4535 + 9e64a83 commit 4afc328
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/html-parser.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ function shouldUseActiveX () {
try {
document.implementation.createHTMLDocument('').open()
} catch (e) {
if (window.ActiveXObject) useActiveX = true
if (root.ActiveXObject) useActiveX = true
}
return useActiveX
}
Expand Down

0 comments on commit 4afc328

Please sign in to comment.