aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--data/matches.json15
-rw-r--r--lib/main.js10
2 files changed, 5 insertions, 20 deletions
diff --git a/data/matches.json b/data/matches.json
deleted file mode 100644
index 25329d6..0000000
--- a/data/matches.json
+++ /dev/null
@@ -1,15 +0,0 @@
-{
- "matches": [
- "https://bugzilla.redhat.com/show_bug.cgi",
- "https://bz-web2-test.devel.redhat.com/show_bug.cgi",
- "https://bugs.freedesktop.org/show_bug.cgi",
- "https://bugzilla.mozilla.org/show_bug.cgi"
- ],
- "skipMatches": [
- "https://bugzilla.redhat.com/(process|post)_bug.cgi",
- "https://bz-web2-test.devel.redhat.com/(process|post)_bug.cgi",
- "https://bugzilla.mozilla.org/post_bug.cgi",
- "https://bugzilla.mozilla.org/process_bug.cgi",
- "https://bugzilla.(redhat.com|mozilla.org)/attachment.cgi$"
- ]
-} \ No newline at end of file
diff --git a/lib/main.js b/lib/main.js
index 43fa87d..a8bae4c 100644
--- a/lib/main.js
+++ b/lib/main.js
@@ -24,11 +24,6 @@ var JSONURLDefault = "https://fedorahosted.org/released"+
"/bugzilla-triage-scripts/Config_data.json";
var config = {};
-(function (){
- var matchesAll = JSON.parse(selfMod.data.load("matches.json"));
- config.matches = matchesAll.matches;
- config.skipMatches = matchesAll.skipMatches;
-})();
function isOurPage(window, matchingURLs) {
var url = window.location.href;
@@ -105,6 +100,11 @@ function initialize(callback) {
config.logger = new logConstructor(myStorage.logs,
JSON.parse(selfMod.data.load("bugzillalabelAbbreviations.json")));
+ config.matches = config.gJSONData.configData.matches;
+ config.skipMatches = config.matches.map(function(x) {
+ return x.replace("show_bug.cgi.*","(process|post)_bug.cgi");
+ });
+
callback(config);
}
}