[Pkg-mozext-commits] [adblock-plus] 02/22: Issue 419 - Work around WebKit bug which breaks element hiding on Safari
David Prévot
taffit at moszumanska.debian.org
Thu Jun 5 14:01:08 UTC 2014
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository adblock-plus.
commit da57df97ed253df2bb57e7221730f354487ca74c
Author: Sebastian Noack <sebastian at adblockplug.org>
Date: Wed May 14 08:13:43 2014 +0200
Issue 419 - Work around WebKit bug which breaks element hiding on Safari
--HG--
extra : rebase_source : c361268d61f534aa2f19159d46f736a6c718a271
---
lib/elemHide.js | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/lib/elemHide.js b/lib/elemHide.js
index 6281101..b5a1473 100644
--- a/lib/elemHide.js
+++ b/lib/elemHide.js
@@ -391,7 +391,7 @@ let ElemHide = exports.ElemHide =
/**
* 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,13 @@ let ElemHide = exports.ElemHide =
for (let key in filterByKey)
{
let filter = filterByKey[key];
- if (specificOnly && (!filter.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
+ let domains = filter.domains;
+
+ if (specificOnly && (!domains || domains[""]))
continue;
if (filter.isActiveOnDomain(domain) && !this.getException(filter, domain))
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/adblock-plus.git
More information about the Pkg-mozext-commits
mailing list