From 3a411cc36bf0deaa9ba9f0784a0239e12ed547e5 Mon Sep 17 00:00:00 2001 From: croneter Date: Thu, 25 Oct 2018 15:57:12 +0200 Subject: [PATCH] Fix TypeError --- resources/lib/library_sync/full_sync.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/resources/lib/library_sync/full_sync.py b/resources/lib/library_sync/full_sync.py index 06111abc..2ff4efff 100644 --- a/resources/lib/library_sync/full_sync.py +++ b/resources/lib/library_sync/full_sync.py @@ -76,7 +76,7 @@ class FullSync(backgroundthread.KillableThread, common.libsync_mixin): """ Processes a single library item """ - plex_id = int(xml_item['ratingKey']) + plex_id = int(xml_item.get('ratingKey')) if self.new_items_only: if self.plex_db.check_plexid(plex_id) is None: backgroundthread.BGThreader.addTask( @@ -85,8 +85,8 @@ class FullSync(backgroundthread.KillableThread, common.libsync_mixin): self.get_children)) else: if self.plex_db.check_checksum( - int('%s%s' % (xml_item['ratingKey'], - xml_item['updatedAt']))) is None: + int('%s%s' % (plex_id, + xml_item.get('updatedAt')))) is None: backgroundthread.BGThreader.addTask( GetMetadataTask().setup(self.queue, plex_id,