1
0
mirror of https://codeberg.org/polarisfm/youtube-dl synced 2024-11-22 16:44:32 +01:00

[Vimeo] Add new embedded type

This commit is contained in:
pihug12 2019-03-27 01:14:31 +01:00
parent 8cb10807ed
commit f7b7401a76

View File

@ -482,10 +482,15 @@ class VimeoIE(VimeoBaseInfoExtractor):
r'<embed[^>]+?src=(["\'])(?P<url>(?:https?:)?//(?:www\.)?vimeo\.com/moogaloop\.swf.+?)\1',
# Look more for non-standard embedded Vimeo player
r'<video[^>]+src=(["\'])(?P<url>(?:https?:)?//(?:www\.)?vimeo\.com/[0-9]+)\1',
# Look for JS embedded Vimeo player
r'<video-player[^>]+vimeo-id="(?P<id>\d+)"',
)
for embed_re in PLAIN_EMBED_RE:
for mobj in re.finditer(embed_re, webpage):
urls.append(mobj.group('url'))
if mobj.group('id'):
urls.append('https://player.vimeo.com/video/' + mobj.group('id'))
else:
urls.append(mobj.group('url'))
return urls
@staticmethod