summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Stefano <l.stickell@yahoo.it> 2014-01-04 18:28:45 +0100
committerGravatar Stefano <l.stickell@yahoo.it> 2014-04-21 16:52:51 +0200
commitbbc7c0e8804027a0d515c264e43d17abcbc83ccb (patch)
treea0fd70c0ee928925dc8cf2a92944c7069377a547
parentStreamcloudEu: increased version number after (diff)
downloadpyload-bbc7c0e8804027a0d515c264e43d17abcbc83ccb.tar.xz
CloudzerNet: improved getInfo
See #185 (cherry picked from commit 561ed2890ec6c4512badcf5ffd3758bc6dafb48d)
-rw-r--r--pyload/plugins/hoster/CloudzerNet.py8
1 files changed, 3 insertions, 5 deletions
diff --git a/pyload/plugins/hoster/CloudzerNet.py b/pyload/plugins/hoster/CloudzerNet.py
index e95f90792..28c4dc6b1 100644
--- a/pyload/plugins/hoster/CloudzerNet.py
+++ b/pyload/plugins/hoster/CloudzerNet.py
@@ -13,10 +13,8 @@ def getInfo(urls):
if 'Location: http://cloudzer.net/404' in header:
file_info = (url, 0, 1, url)
else:
- if url.endswith('/'):
- api_data = getURL(url + 'status')
- else:
- api_data = getURL(url + '/status')
+ fid = re.search(CloudzerNet.__pattern__, url).group('ID')
+ api_data = getURL('http://cloudzer.net/file/%s/status' % fid)
name, size = api_data.splitlines()
size = parseFileSize(size)
file_info = (name, size, 2, url)
@@ -27,7 +25,7 @@ class CloudzerNet(SimpleHoster):
__name__ = "CloudzerNet"
__type__ = "hoster"
__pattern__ = r"http://(www\.)?(cloudzer\.net/file/|clz\.to/(file/)?)(?P<ID>\w+).*"
- __version__ = "0.03"
+ __version__ = "0.04"
__description__ = """Cloudzer.net hoster plugin"""
__author_name__ = ("gs", "z00nx", "stickell")
__author_mail__ = ("I-_-I-_-I@web.de", "z00nx0@gmail.com", "l.stickell@yahoo.it")