Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Browse files

[1.6.x] Fixed backport error in previous commit; refs #15961

  • Loading branch information...
1 parent 9053c6d commit 90bdb42702327a4ef74e74d2e123da0731a90c4c @timgraham timgraham committed
Showing with 2 additions and 3 deletions.
  1. +2 −3 django/contrib/admin/
5 django/contrib/admin/
@@ -756,10 +756,9 @@ def construct_search(field_name):
return "%s__icontains" % field_name
use_distinct = False
- search_fields = self.get_search_fields(request)
- if search_fields and search_term:
+ if self.search_fields and search_term:
orm_lookups = [construct_search(str(search_field))
- for search_field in search_fields]
+ for search_field in self.search_fields]
for bit in search_term.split():
or_queries = [models.Q(**{orm_lookup: bit})
for orm_lookup in orm_lookups]

0 comments on commit 90bdb42

Please sign in to comment.
Something went wrong with that request. Please try again.