mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-07 18:24:30 -04:00
Fix #804383 (TypeError when deleting all saved searches)
This commit is contained in:
parent
d76f1ee48a
commit
f0bf205fea
@ -575,7 +575,9 @@ class TagsView(QTreeView): # {{{
|
||||
expanded_categories, state_map = self.get_state()
|
||||
self._model.rebuild_node_tree(state_map=state_map)
|
||||
for category in expanded_categories:
|
||||
self.expand(self._model.index_for_category(category))
|
||||
idx = self._model.index_for_category(category)
|
||||
if idx is not None and idx.isValid():
|
||||
self.expand(idx)
|
||||
self.show_item_at_path(path)
|
||||
|
||||
def show_item_at_path(self, path, box=False,
|
||||
|
Loading…
x
Reference in New Issue
Block a user