From e048a6184bacd9a87d56b974cf961c093fec24c1 Mon Sep 17 00:00:00 2001 From: DarkFighterLuke Date: Sat, 26 Feb 2022 16:50:40 +0100 Subject: [PATCH] Fix checks on empty data --- youtube_dl/extractor/xvideos.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/youtube_dl/extractor/xvideos.py b/youtube_dl/extractor/xvideos.py index 5102fdffb..42c161bcc 100644 --- a/youtube_dl/extractor/xvideos.py +++ b/youtube_dl/extractor/xvideos.py @@ -151,13 +151,13 @@ class XVideosIE(InfoExtractor): creator_data = re.findall(r'(?P.+?)<', webpage) creator = '' uploader_url = '' - if creator_data is not None: + if creator_data != []: creator = creator_data[0][1] uploader_url = creator_data[0][0] actors_data = re.findall(r'href="(?P/pornstars/.+?)" class="btn btn-default label profile hover-name">(?P.+?)', webpage) actors = [] - if actors_data is not None: + if actors_data != []: for actor_tuple in actors_data: actors.append({ 'given_name': actor_tuple[1],