X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/6822e24c5a6577fb4142fc079eec15816222de45..f258a9896bbeff2a900d8bafb2aecfce03f19bd8:/apps/catalogue/views.py?ds=inline diff --git a/apps/catalogue/views.py b/apps/catalogue/views.py index 7bb82fd4a..29bf80557 100644 --- a/apps/catalogue/views.py +++ b/apps/catalogue/views.py @@ -383,7 +383,7 @@ def find_best_matches(query, user=None): if isinstance(match, models.Book)) authors = set(match.name.lower() for match in result if isinstance(match, models.Tag) and match.category=='author') - result = (res for res in result if not ( + result = tuple(res for res in result if not ( (isinstance(res, pdcounter_models.BookStub) and res.pretty_title().lower() in book_titles) or (isinstance(res, pdcounter_models.Author) and res.name.lower() in authors) ))