From df2b3810bfb7e109c943c3605012fd9823119b50 Mon Sep 17 00:00:00 2001 From: Croneter Date: Tue, 1 May 2018 15:24:58 +0200 Subject: [PATCH] Fix FutureWarning for etree xmls --- resources/lib/playlists.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/lib/playlists.py b/resources/lib/playlists.py index 315092f9..d66aa72e 100644 --- a/resources/lib/playlists.py +++ b/resources/lib/playlists.py @@ -81,7 +81,7 @@ def create_kodi_playlist(plex_id=None): Returns the playlist or raises PL.PlaylistError """ xml = PL.get_PMS_playlist(PL.Playlist_Object(), playlist_id=plex_id) - if not xml: + if xml is None: LOG.error('Could not get Plex playlist %s', plex_id) return api = API(xml) @@ -280,7 +280,7 @@ def full_sync(): LOG.info('Starting playlist full sync') # Get all Plex playlists xml = PL.get_all_playlists() - if not xml: + if xml is None: return False # For each playlist, check Plex database to see whether we already synced # before. If yes, make sure that hashes are identical. If not, sync it.