mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-24 16:21:24 +01:00
Compare commits
3 Commits
cdad3d2cb4
...
01be29d9dd
Author | SHA1 | Date | |
---|---|---|---|
|
01be29d9dd | ||
|
199342bcd1 | ||
|
560367064b |
|
@ -52,7 +52,7 @@ class FacebookIE(InfoExtractor):
|
||||||
)\?(?:.*?)(?:v|video_id|story_fbid)=|
|
)\?(?:.*?)(?:v|video_id|story_fbid)=|
|
||||||
[^/]+/videos/(?:[^/]+/)?|
|
[^/]+/videos/(?:[^/]+/)?|
|
||||||
[^/]+/posts/|
|
[^/]+/posts/|
|
||||||
groups/[^/]+/permalink/|
|
groups/[^/]+/(?:permalink|posts)/|
|
||||||
watchparty/
|
watchparty/
|
||||||
)|
|
)|
|
||||||
facebook:
|
facebook:
|
||||||
|
@ -614,8 +614,8 @@ class FacebookIE(InfoExtractor):
|
||||||
..., 'comet_sections', 'content', 'story', (None, 'attached_story'), 'attachments',
|
..., 'comet_sections', 'content', 'story', (None, 'attached_story'), 'attachments',
|
||||||
..., ('styles', 'throwbackStyles', 'style_type_renderer'), (None, ...), 'attachment'), expected_type=dict) or []
|
..., ('styles', 'throwbackStyles', 'style_type_renderer'), (None, ...), 'attachment'), expected_type=dict) or []
|
||||||
for attachment in attachments:
|
for attachment in attachments:
|
||||||
ns = (try_get(attachment, lambda x: x['all_subattachments']['nodes'], list)
|
ns = traverse_obj(attachment, ('all_subattachments', 'nodes', ..., {dict}),
|
||||||
or traverse_obj(attachment, (..., 'attachments', ..., 'styles', 'attachment'), expected_type=dict) or [])
|
(..., 'attachments', ..., 'styles', 'attachment', {dict}))
|
||||||
for n in ns:
|
for n in ns:
|
||||||
parse_attachment(n)
|
parse_attachment(n)
|
||||||
parse_attachment(attachment)
|
parse_attachment(attachment)
|
||||||
|
@ -638,7 +638,7 @@ class FacebookIE(InfoExtractor):
|
||||||
if len(entries) > 1:
|
if len(entries) > 1:
|
||||||
return self.playlist_result(entries, video_id)
|
return self.playlist_result(entries, video_id)
|
||||||
|
|
||||||
video_info = entries[0] if len(entries) > 0 else {'id': video_id}
|
video_info = entries[0] if entries else {'id': video_id}
|
||||||
webpage_info = extract_metadata(webpage)
|
webpage_info = extract_metadata(webpage)
|
||||||
# honor precise duration in video info
|
# honor precise duration in video info
|
||||||
if video_info.get('duration'):
|
if video_info.get('duration'):
|
||||||
|
|
Loading…
Reference in New Issue
Block a user