From 8ac06f56a164a1860e6c33ac7fd65167d9714cb1 Mon Sep 17 00:00:00 2001 From: Jan Szejko Date: Thu, 4 Feb 2016 12:43:14 +0100 Subject: [PATCH] non-capturing parentheses for diacritics variants --- src/catalogue/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/catalogue/views.py b/src/catalogue/views.py index 09f48c7d4..50dde9f5b 100644 --- a/src/catalogue/views.py +++ b/src/catalogue/views.py @@ -321,7 +321,7 @@ def _no_diacritics_regexp(query): def repl(m): l = m.group() - return u"(%s)" % '|'.join(names[l]) + return u"(?:%s)" % '|'.join(names[l]) return re.sub(u'[%s]' % (u''.join(names.keys())), repl, query) -- 2.20.1