diff options
author | Walter Purcaro <vuolter@users.noreply.github.com> | 2015-04-01 17:39:22 +0200 |
---|---|---|
committer | Walter Purcaro <vuolter@users.noreply.github.com> | 2015-04-01 17:39:22 +0200 |
commit | 55073d5073b6cf80bdb865f79546e871d9bbcbc2 (patch) | |
tree | b90b322795a48fac61caa37bffa1bd3ba30811db | |
parent | [BasePlugin] Fix https://github.com/pyload/pyload/issues/1304 (diff) | |
download | pyload-55073d5073b6cf80bdb865f79546e871d9bbcbc2.tar.xz |
[BasePlugin] Fix https://github.com/pyload/pyload/issues/1304 (2)
-rw-r--r-- | module/plugins/hoster/BasePlugin.py | 6 | ||||
-rw-r--r-- | module/plugins/hoster/Ftp.py | 6 |
2 files changed, 6 insertions, 6 deletions
diff --git a/module/plugins/hoster/BasePlugin.py b/module/plugins/hoster/BasePlugin.py index 7c7e75d33..418f446eb 100644 --- a/module/plugins/hoster/BasePlugin.py +++ b/module/plugins/hoster/BasePlugin.py @@ -13,7 +13,7 @@ from module.plugins.Hoster import Hoster class BasePlugin(Hoster): __name__ = "BasePlugin" __type__ = "hoster" - __version__ = "0.40" + __version__ = "0.41" __pattern__ = r'^unmatchable$' @@ -45,8 +45,8 @@ class BasePlugin(Hoster): def download(self, url, get={}, post={}, ref=True, cookies=True, disposition=False): try: if disposition: - content = urllib2.urlopen(self.link).info()['Content-Disposition'].split(';') - self.pyfile.name = content[1].split('filename=')[1][1:-1] + content = urllib2.urlopen(url).info()['Content-Disposition'].split(';') + self.pyfile.name = content[1].split('filename=')[1][1:-1] or self.pyfile.name finally: return super(BasePlugin, self).download(url, get, post, ref, cookies, False) diff --git a/module/plugins/hoster/Ftp.py b/module/plugins/hoster/Ftp.py index 943701fee..cfe230f42 100644 --- a/module/plugins/hoster/Ftp.py +++ b/module/plugins/hoster/Ftp.py @@ -12,7 +12,7 @@ from module.plugins.Hoster import Hoster class Ftp(Hoster): __name__ = "Ftp" __type__ = "hoster" - __version__ = "0.48" + __version__ = "0.49" __pattern__ = r'(?:ftps?|sftp)://([\w.-]+(:[\w.-]+)?@)?[\w.-]+(:\d+)?/.+' @@ -32,8 +32,8 @@ class Ftp(Hoster): def download(self, url, get={}, post={}, ref=True, cookies=True, disposition=False): try: if disposition: - content = urllib2.urlopen(self.link).info()['Content-Disposition'].split(';') - self.pyfile.name = content[1].split('filename=')[1][1:-1] + content = urllib2.urlopen(url).info()['Content-Disposition'].split(';') + self.pyfile.name = content[1].split('filename=')[1][1:-1] or self.pyfile.name finally: return super(Ftp, self).download(url, get, post, ref, cookies, False) |