mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-02-05 06:58:05 +01:00
Fix #7876 (Books excluded by saved search via tag are visible on server)
This commit is contained in:
parent
a1c7d0615c
commit
ef23a7c8c4
1 changed files with 5 additions and 3 deletions
|
|
@ -552,16 +552,18 @@ def browse_matches(self, category=None, cid=None, list_sort=None):
|
|||
ids = self.search_cache('search:"%s"'%which)
|
||||
except:
|
||||
raise cherrypy.HTTPError(404, 'Search: %r not understood'%which)
|
||||
elif category == 'newest':
|
||||
ids = self.search_cache('')
|
||||
all_ids = self.search_cache('')
|
||||
if category == 'newest':
|
||||
ids = all_ids
|
||||
hide_sort = 'true'
|
||||
elif category == 'allbooks':
|
||||
ids = self.search_cache('')
|
||||
ids = all_ids
|
||||
else:
|
||||
q = category
|
||||
if q == 'news':
|
||||
q = 'tags'
|
||||
ids = self.db.get_books_for_category(q, cid)
|
||||
ids = [x for x in ids if x in all_ids]
|
||||
|
||||
items = [self.db.data._data[x] for x in ids]
|
||||
if category == 'newest':
|
||||
|
|
|
|||
Loading…
Reference in a new issue