Skip to content

Commit

Permalink
Merge pull request #311 from azneto/master
Browse files Browse the repository at this point in the history
modify search to run partial searches rather than starts_with searches
  • Loading branch information
azneto authored May 31, 2021
2 parents 261ceb6 + d94869c commit 5e0ae62
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion machado/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,6 @@ def search(self):
)

for i in q.split():
result |= sqs.filter(text__startswith=i)
result |= sqs.filter(text__contains=i)

return result

0 comments on commit 5e0ae62

Please sign in to comment.