From 0dc8de9dd2d70f33bac243cacb0777c3d8ca8a8b Mon Sep 17 00:00:00 2001 From: Stephan Hradek Date: Wed, 12 Feb 2014 22:34:13 +0100 Subject: [PATCH] fixed an awful typo in the regexp The regexp fails when backslashes are used in the search-regexp. The closing bracket was at the wrong position. --- core/modules/filters.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/modules/filters.js b/core/modules/filters.js index 831ae5780..78f6beacb 100644 --- a/core/modules/filters.js +++ b/core/modules/filters.js @@ -63,7 +63,7 @@ function parseFilterOperation(operators,filterString,p) { nextBracketPos = filterString.indexOf(']',p); break; case '/': // regexp brackets - var rex = /^((?:[^\\\/]*|\\.))*\/(?:\(([mygi]+)\))?/g, + var rex = /^((?:[^\\\/]*|\\.)*)\/(?:\(([mygi]+)\))?/g, rexMatch = rex.exec(filterString.substring(p)); if(rexMatch) { operator.regexp = new RegExp(rexMatch[1], rexMatch[2]);