Skip to content

Commit

Permalink
[gfycat] Extend _VALID_URL (#22225)
Browse files Browse the repository at this point in the history
  • Loading branch information
AnhNhan authored and meunierd committed Feb 13, 2020
1 parent 2be888b commit b139954
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion youtube_dl/extractor/gfycat.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@


class GfycatIE(InfoExtractor):
_VALID_URL = r'https?://(?:www\.)?gfycat\.com/(?:ru/|ifr/|gifs/detail/)?(?P<id>[^-/?#]+)'
_VALID_URL = r'https?://(?:(?:www|giant|thumbs)\.)?gfycat\.com/(?:ru/|ifr/|gifs/detail/)?(?P<id>[^-/?#\.]+)'
_TESTS = [{
'url': 'http://gfycat.com/DeadlyDecisiveGermanpinscher',
'info_dict': {
Expand Down Expand Up @@ -53,6 +53,12 @@ class GfycatIE(InfoExtractor):
}, {
'url': 'https://gfycat.com/acceptablehappygoluckyharborporpoise-baseball',
'only_matching': True
}, {
'url': 'https://thumbs.gfycat.com/acceptablehappygoluckyharborporpoise-size_restricted.gif',
'only_matching': True
}, {
'url': 'https://giant.gfycat.com/acceptablehappygoluckyharborporpoise.mp4',
'only_matching': True
}]

def _real_extract(self, url):
Expand Down

0 comments on commit b139954

Please sign in to comment.