From 14386e733284ff78c5429d5e31da570d78de7285 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Elan=20Ruusam=C3=A4e?= Date: Wed, 10 Jul 2024 02:25:29 +0300 Subject: [PATCH] Use section_id property --- plextraktsync/plex/PlexLibraryItem.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/plextraktsync/plex/PlexLibraryItem.py b/plextraktsync/plex/PlexLibraryItem.py index 4115fda6c2..b154c7a17d 100644 --- a/plextraktsync/plex/PlexLibraryItem.py +++ b/plextraktsync/plex/PlexLibraryItem.py @@ -41,9 +41,7 @@ def section_id(self): @cached_property def is_discover(self): - # Use __dict__ access to prevent reloads: - # https://github.com/pkkid/python-plexapi/pull/1093 - return self.item.__dict__["librarySectionID"] is None + return self.section_id is None @property def web_url(self): @@ -128,10 +126,10 @@ def library(self): if self.is_discover: return None - if self.item.librarySectionID not in self.plex.library_sections: + if self.section_id not in self.plex.library_sections: return None - return self.plex.library_sections[self.item.librarySectionID] + return self.plex.library_sections[self.section_id] @cached_property def edition_title(self):