1
0
Fork 0
mirror of synced 2024-06-26 10:00:20 +12:00

Fixed request headers

This commit is contained in:
Ali Parlakci 2018-08-08 00:47:34 +03:00
parent 3e6dfccdd2
commit 4c8de50880

View file

@ -61,7 +61,7 @@ def getFile(fileDir,tempDir,imageURL,indent=0):
("Accept", "text/html,application/xhtml+xml,application/xml;" \
"q=0.9,image/webp,image/apng,*/*;q=0.8"),
("Accept-Charset", "ISO-8859-1,utf-8;q=0.7,*;q=0.3"),
("Accept-Encoding", "gzip, deflate, br"),
("Accept-Encoding", "none"),
("Accept-Language", "en-US,en;q=0.8"),
("Connection", "keep-alive")
]
@ -401,6 +401,8 @@ class Gfycat:
except IndexError:
raise NotADownloadableLinkError("Could not read the page source")
except Exception as exception:
#debug
raise exception
raise NotADownloadableLinkError("Could not read the page source")
POST['postExt'] = getExtension(POST['mediaURL'])