Index: lib/elemHide.js |
=================================================================== |
--- a/lib/elemHide.js |
+++ b/lib/elemHide.js |
@@ -391,7 +391,7 @@ |
/** |
* Returns a list of all selectors active on a particular domain (currently |
- * used only in Chrome). |
+ * used only in Chrome, Opera and Safari). |
*/ |
getSelectorsForDomain: function(/**String*/ domain, /**Boolean*/ specificOnly) |
{ |
@@ -399,7 +399,11 @@ |
for (let key in filterByKey) |
{ |
let filter = filterByKey[key]; |
- if (specificOnly && (!filter.domains || filter.domains[""])) |
+ let domains = filter.domains; // it is important to always access filter.domains |
+ // here, even if it isn't used, in order to |
+ // workaround WebKit bug 132872, also see #419 |
Wladimir Palant
2014/05/14 06:17:37
Nit: Please always put comments with more than two
Sebastian Noack
2014/05/14 06:40:19
Done.
|
+ |
+ if (specificOnly && (!domains || domains[""])) |
continue; |
if (filter.isActiveOnDomain(domain) && !this.getException(filter, domain)) |