From b0664a3b51bf2a24d6a38ba2c21328e266322b85 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Elan=20Ruusam=C3=A4e?= Date: Tue, 11 Jun 2024 19:48:42 +0300 Subject: [PATCH] Keep plex_items_sorted as property --- plextraktsync/sync/TraktListsPlugin.py | 3 +-- plextraktsync/trakt/TraktUserList.py | 1 + 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/plextraktsync/sync/TraktListsPlugin.py b/plextraktsync/sync/TraktListsPlugin.py index 4edab822ba..a670ea0e7a 100644 --- a/plextraktsync/sync/TraktListsPlugin.py +++ b/plextraktsync/sync/TraktListsPlugin.py @@ -52,8 +52,7 @@ async def fini(self, dry_run: bool): with measure_time("Updated Trakt Lists"): for tl in self.trakt_lists: - items = tl.plex_items_sorted() - updated = tl.plex_list.update(items) + updated = tl.plex_list.update(tl.plex_items_sorted) if not updated: continue self.logger.info( diff --git a/plextraktsync/trakt/TraktUserList.py b/plextraktsync/trakt/TraktUserList.py index 05a43ce67f..40001e37ef 100644 --- a/plextraktsync/trakt/TraktUserList.py +++ b/plextraktsync/trakt/TraktUserList.py @@ -124,6 +124,7 @@ def add(self, m: Media): def title_link(self): return self.plex_list.title_link + @property def plex_items_sorted(self): """ Returns items sorted by trakt rank