diff options
author | Stefano <l.stickell@yahoo.it> | 2013-05-20 12:41:16 +0200 |
---|---|---|
committer | Stefano <l.stickell@yahoo.it> | 2013-05-20 12:41:16 +0200 |
commit | 5fce9b9761537b1e171d137fe32239d5ea38566f (patch) | |
tree | 8f5f69b93007aae830f0541572ad972ee8c0a96b | |
parent | XvidstageCom: code reformat (diff) | |
download | pyload-5fce9b9761537b1e171d137fe32239d5ea38566f.tar.xz |
Premium4Me: error handled
http://forum.pyload.org/viewtopic.php?f=12&t=2587
-rw-r--r-- | module/plugins/hoster/Premium4Me.py | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/module/plugins/hoster/Premium4Me.py b/module/plugins/hoster/Premium4Me.py index 2679916e9..1c65a85a4 100644 --- a/module/plugins/hoster/Premium4Me.py +++ b/module/plugins/hoster/Premium4Me.py @@ -9,13 +9,13 @@ from os import remove class Premium4Me(Hoster):
__name__ = "Premium4Me"
- __version__ = "0.04"
+ __version__ = "0.05"
__type__ = "hoster"
__pattern__ = r"http://premium4.me/.*"
__description__ = """premium4.me hoster plugin"""
- __author_name__ = ("RaNaN", "zoidberg")
- __author_mail__ = ("RaNaN@pyload.org", "zoidberg@mujmail.cz")
+ __author_name__ = ("RaNaN", "zoidberg", "stickell")
+ __author_mail__ = ("RaNaN@pyload.org", "zoidberg@mujmail.cz", "l.stickell@yahoo.it")
def setup(self):
self.resumeDownload = True
@@ -34,7 +34,12 @@ class Premium4Me(Hoster): self.req.setOption("timeout", 120)
self.download("http://premium4.me/api/getfile.php?authcode=%s&link=%s" % (self.account.authcode, quote(pyfile.url, "")), disposition=True)
-
+
+ check = self.checkDownload({"nopremium": "No premium account available"})
+
+ if check == "nopremium":
+ self.retry(3, 60, 'No premium account available')
+
err = ''
if self.req.http.code == '420':
# Custom error code send - fail
|