From f32a8c534f868b9fcf90f15ea4a95d05b2d74546 Mon Sep 17 00:00:00 2001 From: croneter Date: Tue, 25 Jun 2019 18:12:46 +0200 Subject: [PATCH] Fix FutureWarning --- resources/lib/entrypoint.py | 2 +- resources/lib/plex_api/base.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/lib/entrypoint.py b/resources/lib/entrypoint.py index 162d1c38..3225515f 100644 --- a/resources/lib/entrypoint.py +++ b/resources/lib/entrypoint.py @@ -483,7 +483,7 @@ def extras(plex_id): xbmcplugin.endOfDirectory(int(sys.argv[1])) return extras = API(xml[0]).extras() - if not extras: + if extras is None: return for child in xml: xml.remove(child) diff --git a/resources/lib/plex_api/base.py b/resources/lib/plex_api/base.py index f6c61b73..5228accb 100644 --- a/resources/lib/plex_api/base.py +++ b/resources/lib/plex_api/base.py @@ -561,7 +561,7 @@ class Base(object): Returns None if no extras are found """ extras = self.xml.find('Extras') - if not extras: + if extras is None: return return (x for x in extras)