Enabled search for archived books

This commit is contained in:
Ozzieisaacs
2020-05-27 19:19:17 +02:00
parent 9b2df9cfd9
commit 27ed918896
2 changed files with 11 additions and 12 deletions
+1 -2
View File
@@ -572,8 +572,7 @@ class CalibreDB(threading.Thread):
authorterms = re.split("[, ]+", term)
for authorterm in authorterms:
q.append(Books.authors.any(func.lower(Authors.name).ilike("%" + authorterm + "%")))
return self.session.query(Books).filter(self.common_filters()).filter(
return self.session.query(Books).filter(self.common_filters(True)).filter(
or_(Books.tags.any(func.lower(Tags.name).ilike("%" + term + "%")),
Books.series.any(func.lower(Series.name).ilike("%" + term + "%")),
Books.authors.any(and_(*q)),