mirror of
https://github.com/spaam/svtplay-dl.git
synced 2024-11-27 21:54:17 +01:00
download_http: add an extension if we cant find one
This commit is contained in:
parent
9f176d4cc4
commit
9251429dca
@ -33,6 +33,8 @@ def download_http(options, url):
|
|||||||
extension = re.search("(\.[a-z0-9]+)$", url)
|
extension = re.search("(\.[a-z0-9]+)$", url)
|
||||||
if extension:
|
if extension:
|
||||||
options.output = options.output + extension.group(1)
|
options.output = options.output + extension.group(1)
|
||||||
|
else:
|
||||||
|
options.output = "%s.mp4" % options.output
|
||||||
log.info("Outfile: %s", options.output)
|
log.info("Outfile: %s", options.output)
|
||||||
file_d = open(options.output, "wb")
|
file_d = open(options.output, "wb")
|
||||||
else:
|
else:
|
||||||
|
Loading…
Reference in New Issue
Block a user