mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-10 10:23:16 +00:00
[extractor/common] Improve jwplayer subtitles extraction
This commit is contained in:
parent
0ea6efbb7a
commit
96a2daa1ee
|
@ -2299,6 +2299,8 @@ def _parse_jwplayer_data(self, jwplayer_data, video_id=None, require_title=True,
|
||||||
tracks = video_data.get('tracks')
|
tracks = video_data.get('tracks')
|
||||||
if tracks and isinstance(tracks, list):
|
if tracks and isinstance(tracks, list):
|
||||||
for track in tracks:
|
for track in tracks:
|
||||||
|
if not isinstance(track, dict):
|
||||||
|
continue
|
||||||
if track.get('kind') != 'captions':
|
if track.get('kind') != 'captions':
|
||||||
continue
|
continue
|
||||||
track_url = urljoin(base_url, track.get('file'))
|
track_url = urljoin(base_url, track.get('file'))
|
||||||
|
|
Loading…
Reference in a new issue