We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 2cc37a8 + 76d8de3 commit 996d903Copy full SHA for 996d903
src/ElementQueries.js
@@ -232,7 +232,13 @@
232
this.init = function(withTracking) {
233
this.withTracking = withTracking;
234
for (var i = 0, j = document.styleSheets.length; i < j; i++) {
235
- readRules(document.styleSheets[i].cssText || document.styleSheets[i].cssRules || document.styleSheets[i].rules);
+ try {
236
+ readRules(document.styleSheets[i].cssText || document.styleSheets[i].cssRules || document.styleSheets[i].rules);
237
+ } catch(e) {
238
+ if (e.name !== 'SecurityError') {
239
+ throw e;
240
+ }
241
242
}
243
};
244
0 commit comments