mirror of
https://github.com/Hopiu/wagtail.git
synced 2026-05-01 03:54:48 +00:00
Don't normalise query strings on search Fixes #937
This commit is contained in:
parent
36f782dc03
commit
51d6a69d3d
2 changed files with 0 additions and 6 deletions
|
|
@ -7,7 +7,6 @@ from django.db.models.sql.where import SubqueryConstraint, WhereNode
|
|||
from django.core.exceptions import ImproperlyConfigured
|
||||
|
||||
from wagtail.wagtailsearch.index import class_is_indexed
|
||||
from wagtail.wagtailsearch.utils import normalise_query_string
|
||||
|
||||
|
||||
class FilterError(Exception):
|
||||
|
|
@ -213,10 +212,6 @@ class BaseSearch(object):
|
|||
if not class_is_indexed(model):
|
||||
return []
|
||||
|
||||
# Normalise query string
|
||||
if query_string is not None:
|
||||
query_string = normalise_query_string(query_string)
|
||||
|
||||
# Check that theres still a query string after the clean up
|
||||
if query_string == "":
|
||||
return []
|
||||
|
|
|
|||
|
|
@ -135,7 +135,6 @@ class TestElasticSearchBackend(BackendTests, TestCase):
|
|||
# Even though they both start with the letter "H". This should not be considered a match
|
||||
self.assertEqual(len(results), 0)
|
||||
|
||||
@unittest.expectedFailure
|
||||
def test_search_with_hyphen(self):
|
||||
"""
|
||||
This tests that punctuation characters are treated the same
|
||||
|
|
|
|||
Loading…
Reference in a new issue