[Pkg-mozext-commits] [wot] 20/226: Allow search rules to specify the maximum reputation level for which rating symbols are shown. This allows exclusion of green rating symbols from Gmail only, for example.

David Prévot taffit at moszumanska.debian.org
Fri May 1 00:35:30 UTC 2015


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository wot.

commit 8b32d0ef8ebd2b0ef823435a80ab9742fd3acf8a
Author: Sami Tolvanen <sami at mywot.com>
Date:   Mon Apr 9 21:39:31 2012 +0300

    Allow search rules to specify the maximum reputation level for which rating symbols are shown. This allows exclusion of green rating symbols from Gmail only, for example.
---
 content/config.js | 3 ++-
 content/search.js | 8 +++++---
 2 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/content/config.js b/content/config.js
index 22aef81..8b8a889 100644
--- a/content/config.js
+++ b/content/config.js
@@ -19,7 +19,7 @@
 */
 
 const WOT_PLATFORM = "firefox";
-const WOT_VERSION  = "20120304";
+const WOT_VERSION  = "20120409";
 
 /*
  * Constants
@@ -279,6 +279,7 @@ const WOT_SEARCH_PRE_RE			= "re";
 const WOT_SEARCH_PRESTYLE		= "prestyle";
 const WOT_SEARCH_REMOVE			= "remove";
 const WOT_SEARCH_SCRIPT			= "script";
+const WOT_SEARCH_SEARCHLEVEL	= "searchlevel";
 const WOT_SEARCH_STYLE			= "style";
 const WOT_SEARCH_URLIGN			= "urlign";
 const WOT_SEARCH_URL			= "url";
diff --git a/content/search.js b/content/search.js
index fd17941..fe24af1 100644
--- a/content/search.js
+++ b/content/search.js
@@ -1,6 +1,6 @@
 /*
 	search.js
-	Copyright © 2006, 2007, 2008, 2009  WOT Services Oy <info at mywot.com>
+	Copyright © 2006-2012  WOT Services Oy <info at mywot.com>
 
 	This file is part of WOT.
 
@@ -27,11 +27,12 @@ var wot_search =
 			WOT_SEARCH_URLIGN,
 			WOT_SEARCH_PRESTYLE,
 			WOT_SEARCH_SCRIPT,
-			WOT_SEARCH_STYLE,
+			WOT_SEARCH_STYLE
 		],
 
 	attrint: [
 			WOT_SEARCH_DYNAMIC,
+			WOT_SEARCH_SEARCHLEVEL
 		],
 
 	load_delayed: function()
@@ -1173,7 +1174,8 @@ var wot_search =
 
 			var r = this.getreputation(name);
 
-			if (wot_prefs.use_search_level && r >= wot_prefs.search_level) {
+			if ((wot_prefs.use_search_level && r >= wot_prefs.search_level) ||
+					(rule.searchlevel != null && r >= rule.searchlevel)) {
 				return "";
 			}
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/wot.git



More information about the Pkg-mozext-commits mailing list