ignore whitespace around pages regexps

Patch by Simon B��nzli.
bug=343979
r=myk
This commit is contained in:
myk@mozilla.org
2007-01-14 05:38:06 +00:00
parent 22e6ac8800
commit a95f0d5f83

View File

@@ -1207,7 +1207,8 @@ MicrosummaryGenerator.prototype = {
node.namespaceURI != MICSUM_NS ||
(node.nodeName != "include" && node.nodeName != "exclude"))
continue;
this._rules.push({ type: node.nodeName, regexp: new RegExp(node.textContent) });
var urlRegexp = node.textContent.replace(/^\s+|\s+$/g, "");
this._rules.push({ type: node.nodeName, regexp: new RegExp(urlRegexp) });
}
}