Redgif image fixes
This commit is contained in:
@@ -45,9 +45,7 @@ class Redgifs(BaseDownloader):
|
|||||||
elif response_json['gif']['type'] == 2: # type 2 is an image
|
elif response_json['gif']['type'] == 2: # type 2 is an image
|
||||||
if response_json['gif']['gallery']:
|
if response_json['gif']['gallery']:
|
||||||
content = Redgifs.retrieve_url(
|
content = Redgifs.retrieve_url(
|
||||||
f'https://api.redgifs.com/v2/gallery/{response_json["gif"]["gallery"]}',
|
f'https://api.redgifs.com/v2/gallery/{response_json["gif"]["gallery"]}')
|
||||||
headers=headers,
|
|
||||||
)
|
|
||||||
response_json = json.loads(content.text)
|
response_json = json.loads(content.text)
|
||||||
out = {p['urls']['hd'] for p in response_json['gifs']}
|
out = {p['urls']['hd'] for p in response_json['gifs']}
|
||||||
else:
|
else:
|
||||||
|
|||||||
Reference in New Issue
Block a user