Skip to content

Commit

Permalink
[redgifs] support gifsdeliverynetwork.com URLs (#874)
Browse files Browse the repository at this point in the history
  • Loading branch information
mikf committed Jul 9, 2020
1 parent f1344fe commit 3424fb9
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions gallery_dl/extractor/redgifs.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,15 @@ def gfycats(self):
class RedgifsImageExtractor(RedgifsExtractor):
"""Extractor for individual gifs from redgifs.com"""
subcategory = "image"
pattern = r"(?:https?://)?(?:www\.)?redgifs\.com/watch/([A-Za-z]+)"
test = ("https://redgifs.com/watch/foolishforkedabyssiniancat", {
"pattern": r"https://\w+.redgifs.com/FoolishForkedAbyssiniancat.mp4",
"content": "f6e03f1df9a2ff2a74092f53ee7580d2fb943533",
})
pattern = (r"(?:https?://)?(?:www\.)?(?:redgifs\.com/watch"
r"|gifdeliverynetwork.com)/([A-Za-z]+)")
test = (
("https://redgifs.com/watch/foolishforkedabyssiniancat", {
"pattern": r"https://\w+.redgifs.com/FoolishForkedAbyss.+.mp4",
"content": "f6e03f1df9a2ff2a74092f53ee7580d2fb943533",
}),
("https://www.gifdeliverynetwork.com/foolishforkedabyssiniancat"),
)

def gfycats(self):
return (RedgifsAPI(self).gfycat(self.key),)
Expand Down

0 comments on commit 3424fb9

Please sign in to comment.