mirror of
https://github.com/ytdl-org/youtube-dl.git
synced 2024-11-16 06:17:27 +00:00
minor fixes
This commit is contained in:
parent
5507979402
commit
e3a900e707
@ -9,7 +9,7 @@ from ..utils import unified_strdate, parse_duration
|
|||||||
def get_thumbnail(data):
|
def get_thumbnail(data):
|
||||||
for media in data.get('media_group', []):
|
for media in data.get('media_group', []):
|
||||||
if media.get('type') == 'image':
|
if media.get('type') == 'image':
|
||||||
for item in media.get('media_item'):
|
for item in media.get('media_item', []):
|
||||||
thumbnail = item.get('src')
|
thumbnail = item.get('src')
|
||||||
if thumbnail:
|
if thumbnail:
|
||||||
return thumbnail
|
return thumbnail
|
||||||
@ -53,11 +53,11 @@ class KanIE(InfoExtractor):
|
|||||||
return {}
|
return {}
|
||||||
|
|
||||||
def _extract_list(self, list_id, webpage):
|
def _extract_list(self, list_id, webpage):
|
||||||
ids = re.findall(r'onclick="playVideo\(.*,\'([0-9]+)\'\)', webpage)
|
video_ids = re.findall(r'onclick="playVideo\(.*,\'([0-9]+)\'\)', webpage)
|
||||||
title = self._og_search_title(webpage)
|
title = self._og_search_title(webpage)
|
||||||
description = self._og_search_description(webpage)
|
description = self._og_search_description(webpage)
|
||||||
entries = []
|
entries = []
|
||||||
for video_id in ids:
|
for video_id in video_ids:
|
||||||
url = 'https://www.kan.org.il/Item/?itemId=%s' % video_id
|
url = 'https://www.kan.org.il/Item/?itemId=%s' % video_id
|
||||||
webpage = self._download_webpage(
|
webpage = self._download_webpage(
|
||||||
url,
|
url,
|
||||||
|
Loading…
Reference in New Issue
Block a user