Skip to content

Commit

Permalink
Fix failure with regex include/exclude rules.
Browse files Browse the repository at this point in the history
Fixes #1692
  • Loading branch information
arantius committed Jan 18, 2013
1 parent d40eb98 commit 41cd0be
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions modules/third-party/convert2RegExp.js
Expand Up @@ -41,6 +41,10 @@ var eTldService = Components
function GM_convert2RegExp(pattern, uri) {
var reStr = GM_convert2RegExpInner(pattern);

// Inner returns a RegExp, not str, for input regex (not glob) patterns.
// Use those directly without magic TLD modifications.
if (reStr instanceof RegExp) return reStr;

if (uri && reStr.match(tldRegExp)) {
var tld = null;
try {
Expand Down

0 comments on commit 41cd0be

Please sign in to comment.