aboutsummaryrefslogtreecommitdiffstats
path: root/lib/main.js
diff options
context:
space:
mode:
authorMatěj Cepl <mcepl@redhat.com>2010-07-17 09:04:48 +0200
committerMatěj Cepl <mcepl@redhat.com>2010-07-17 09:13:52 +0200
commit34ae7055a0f01306be67dc00030af93190deca55 (patch)
treebec978682872324e92aa7ffdcdcab32e99113a49 /lib/main.js
parent90ae10b0d1181cedb1c31a20e2194a59896223fd (diff)
downloadbugzilla-triage-34ae7055a0f01306be67dc00030af93190deca55.tar.gz
Make XMLRPC service independent of a bugzilla instance.
- activates password dialog only for bugzillas which actually need it - XML-RPC URL is stored in data/XMLRPCdata.json Fixes #23
Diffstat (limited to 'lib/main.js')
-rw-r--r--lib/main.js5
1 files changed, 1 insertions, 4 deletions
diff --git a/lib/main.js b/lib/main.js
index 07ef3c6..66f90f9 100644
--- a/lib/main.js
+++ b/lib/main.js
@@ -15,7 +15,6 @@ var util = require("util");
var logger = require("logger");
var myStorage = require("simple-storage").storage;
var browser = require("tab-browser");
-var urlMod = require("url");
var selfMod = require("self");
var Request = require("request").Request;
var preferences = require("preferences-service");
@@ -24,8 +23,6 @@ var BTSPrefNS = require("bzpage").BTSPrefNS;
var JSONURLDefault = "https://fedorahosted.org/released"+
"/bugzilla-triage-scripts/Config_data.json";
-var XMLRPCurl = "https://bugzilla.redhat.com/xmlrpc.cgi";
-
var config = {};
(function (){
var matchesAll = JSON.parse(selfMod.data.load("matches.json"));
@@ -49,7 +46,7 @@ function skipThisPage(doc) {
var stemURL = "https://HOSTNAME/show_bug.cgi?id=";
var titleStr = doc.getElementsByTagName("title")[0].textContent;
var REArr = new RegExp("[bB]ug\\s+([0-9]+)").exec(titleStr);
- var hostname = urlMod.URL(doc.location.href).host;
+ var hostname = doc.location.hostname;
if (REArr) {
var bugNo = REArr[1];
var emailsSent = doc.