1
0
mirror of https://github.com/l1ving/youtube-dl synced 2025-03-07 15:57:15 +08:00

bitchute - added magnet link extraction

This commit is contained in:
Georgi Saev 2019-07-08 10:40:26 +03:00 committed by GitHub
parent a6389abfd7
commit 42a4deb953
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -73,6 +73,12 @@ class BitChuteIE(InfoExtractor):
(r'(?s)<div class=["\']channel-banner.*?<p\b[^>]+\bclass=["\']name[^>]+>(.+?)</p>',
r'(?s)<p\b[^>]+\bclass=["\']video-author[^>]+>(.+?)</p>'),
webpage, 'uploader', fatal=False)
magnet_link = self._html_search_regex(
r'(?s)<div class="video-actions">.*<a href=["\'](magnet:.+?)["\'][^>][^>]+>', webpage,
'magnet_link', fatal=False)
return {
'id': video_id,
@ -81,6 +87,7 @@ class BitChuteIE(InfoExtractor):
'thumbnail': thumbnail,
'uploader': uploader,
'formats': formats,
'magnet_link': magnet_link,
}