Skip to content

Commit

Permalink
fix: slow api calls due to calculating state for every item
Browse files Browse the repository at this point in the history
  • Loading branch information
Gaisberg authored and Gaisberg committed Sep 12, 2024
1 parent 46a6510 commit f5e08f8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/program/media/item.py
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ def to_dict(self):
"imdb_id": self.imdb_id if hasattr(self, "imdb_id") else None,
"tvdb_id": self.tvdb_id if hasattr(self, "tvdb_id") else None,
"tmdb_id": self.tmdb_id if hasattr(self, "tmdb_id") else None,
"state": self.state.value if self.state else self.last_state,
"state": self.last_state,
"imdb_link": self.imdb_link if hasattr(self, "imdb_link") else None,
"aired_at": str(self.aired_at),
"genres": self.genres if hasattr(self, "genres") else None,
Expand Down

0 comments on commit f5e08f8

Please sign in to comment.