From 41483e67315a5861ad3fd63984ac47972d3ebafe Mon Sep 17 00:00:00 2001 From: croneter Date: Sun, 17 Mar 2019 15:31:02 +0100 Subject: [PATCH] Add more exit points when synching --- resources/lib/library_sync/full_sync.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/resources/lib/library_sync/full_sync.py b/resources/lib/library_sync/full_sync.py index 80973562..003452a8 100644 --- a/resources/lib/library_sync/full_sync.py +++ b/resources/lib/library_sync/full_sync.py @@ -410,7 +410,7 @@ class FullSync(common.fullsync_mixin): def _run(self): self.current_sync = timing.plex_now() # Get latest Plex libraries and build playlist and video node files - if not sections.sync_from_pms(self): + if self.isCanceled() or not sections.sync_from_pms(self): return self.successful = True try: @@ -422,10 +422,7 @@ class FullSync(common.fullsync_mixin): # Actual syncing - do only new items first LOG.info('Running full_library_sync with repair=%s', self.repair) - if not self.full_library_sync(): - self.successful = False - return - if self.isCanceled(): + if self.isCanceled() or not self.full_library_sync(): self.successful = False return if common.PLAYLIST_SYNC_ENABLED and not playlists.full_sync():