diff options
Diffstat (limited to 'searx/utils.py')
-rw-r--r-- | searx/utils.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/searx/utils.py b/searx/utils.py index 219135a4b..c027bff20 100644 --- a/searx/utils.py +++ b/searx/utils.py @@ -63,7 +63,7 @@ def highlight_content(content, query): regex_parts = [] for chunk in query.split(): if len(chunk) == 1: - regex_parts.append(u'\W+{0}\W+'.format(re.escape(chunk))) + regex_parts.append(u'\\W+{0}\\W+'.format(re.escape(chunk))) else: regex_parts.append(u'{0}'.format(re.escape(chunk))) query_regex = u'({0})'.format('|'.join(regex_parts)) |