From ecaced7b5c8b9a390770f2a9e040291e30826bbf Mon Sep 17 00:00:00 2001 From: Johan Andersson Date: Sat, 23 Mar 2019 02:02:11 +0100 Subject: [PATCH] dashparse: use == compare ints.. --- lib/svtplay_dl/fetcher/dash.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/svtplay_dl/fetcher/dash.py b/lib/svtplay_dl/fetcher/dash.py index 74d0f7c..a4dc169 100644 --- a/lib/svtplay_dl/fetcher/dash.py +++ b/lib/svtplay_dl/fetcher/dash.py @@ -168,11 +168,11 @@ def _dashparse(config, text, url, output, cookies): duration_sec = (parse_dates(mediaPresentationDuration) - datetime(1900, 1, 1)).total_seconds() temp = xml.findall('.//{urn:mpeg:dash:schema:mpd:2011}AdaptationSet[@mimeType="audio/mp4"]') - if len(temp) is 0: + if len(temp) == 0: temp = xml.findall('.//{urn:mpeg:dash:schema:mpd:2011}AdaptationSet[@contentType="audio"]') audiofiles = adaptionset(temp, url, baseurl, offset_sec, duration_sec) temp = xml.findall('.//{urn:mpeg:dash:schema:mpd:2011}AdaptationSet[@mimeType="video/mp4"]') - if len(temp) is 0: + if len(temp) == 0: temp = xml.findall('.//{urn:mpeg:dash:schema:mpd:2011}AdaptationSet[@contentType="video"]') videofiles = adaptionset(temp, url, baseurl, offset_sec, duration_sec)