diff --git a/rest_framework/filters.py b/rest_framework/filters.py index a0f480190..6397abdfe 100644 --- a/rest_framework/filters.py +++ b/rest_framework/filters.py @@ -52,7 +52,7 @@ class SearchFilter(BaseFilterBackend): def get_search_fields(self, view, request): """ - Search fields are obtained from the view / search backend, but the request is + Search fields are obtained from the view / search backend, but the request is always passed to this method. Sub-classes can override this method to dynamically change the search fields based on request content. """ diff --git a/tests/test_filters.py b/tests/test_filters.py index 910ec58a0..697301213 100644 --- a/tests/test_filters.py +++ b/tests/test_filters.py @@ -218,7 +218,6 @@ class SearchFilterTests(TestCase): {'id': 3, 'title': 'zzz', 'text': 'cde'} ] - def test_search_field_with_null_characters(self): view = generics.GenericAPIView() request = factory.get('/?search=\0as%00d\x00f')