Skip to content

Commit

Permalink
fix: add check to see if library is loaded in filter_items (TagStudio…
Browse files Browse the repository at this point in the history
…Dev#547)

* Added a check to see if the library is loaded in filter_items

* Returned check to see if there is an engine

---------

Co-authored-by: gred <gred25@yandex.ru>
  • Loading branch information
2 people authored and DandyDev01 committed Dec 13, 2024
1 parent 78b60c5 commit e21b332
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tagstudio/src/qt/ts_qt.py
Original file line number Diff line number Diff line change
Expand Up @@ -1118,6 +1118,9 @@ def update_badges(self, grid_item_ids: Sequence[int] = None):
self.item_thumbs[grid_idx].refresh_badge(entry)

def filter_items(self, filter: FilterState | None = None) -> None:
if not self.lib.library_dir:
logger.info("Library not loaded")
return
assert self.lib.engine

if filter:
Expand Down

0 comments on commit e21b332

Please sign in to comment.