mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2025-08-15 00:48:28 +00:00
Fix broken extractor
The previous code completely broke the extractor
This commit is contained in:
parent
c2e75eade9
commit
e84e5074fd
@ -114,18 +114,14 @@ def _real_extract(self, url):
|
|||||||
raise ExtractorError('Unable to extract video URL')
|
raise ExtractorError('Unable to extract video URL')
|
||||||
vid_url = urljoin('https://video.fc2.com/', vid_url)
|
vid_url = urljoin('https://video.fc2.com/', vid_url)
|
||||||
|
|
||||||
if vidplaylist.get('type') == '1':
|
video_type = vidplaylist.get('type')
|
||||||
formats = self._extract_m3u8_formats(vid_url, video_id, 'mp4')
|
|
||||||
else:
|
|
||||||
formats = [{
|
|
||||||
'url': vid_url,
|
|
||||||
'ext': 'mp4',
|
|
||||||
}]
|
|
||||||
|
|
||||||
return {
|
return {
|
||||||
'id': video_id,
|
'id': video_id,
|
||||||
'title': title,
|
'title': title,
|
||||||
'formats': formats,
|
'url': vid_url,
|
||||||
|
'ext': 'mp4',
|
||||||
|
'protocol': 'm3u8_native' if video_type == 2 else 'https',
|
||||||
'description': description,
|
'description': description,
|
||||||
'thumbnail': thumbnail,
|
'thumbnail': thumbnail,
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user