summaryrefslogtreecommitdiffstats
path: root/pyload/plugins/hoster/XFileSharingPro.py
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@gmail.com> 2014-04-11 12:17:38 +0200
committerGravatar Stefano <l.stickell@yahoo.it> 2014-04-21 17:20:14 +0200
commit52b5c2a15b2dfa9bcc2ffdcc90b8e3f29fdaa7d8 (patch)
treebe392f70e0d628a97e793ef47080e0669420e33a /pyload/plugins/hoster/XFileSharingPro.py
parentFix retry time formats (diff)
downloadpyload-52b5c2a15b2dfa9bcc2ffdcc90b8e3f29fdaa7d8.tar.xz
Use wait to set time in SimpleHoster plugins
Merges vuolter/pyload@bb002ac (cherry picked from commit 7f1467c64fe5c0e902498b3252afd65cb68ed2f9)
Diffstat (limited to 'pyload/plugins/hoster/XFileSharingPro.py')
-rw-r--r--pyload/plugins/hoster/XFileSharingPro.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/pyload/plugins/hoster/XFileSharingPro.py b/pyload/plugins/hoster/XFileSharingPro.py
index ce190f2fe..3859d954e 100644
--- a/pyload/plugins/hoster/XFileSharingPro.py
+++ b/pyload/plugins/hoster/XFileSharingPro.py
@@ -215,15 +215,13 @@ class XFileSharingPro(SimpleHoster):
if 'wait' in self.errmsg:
wait_time = sum([int(v) * {"hour": 3600, "minute": 60, "second": 1}[u] for v, u in
re.findall(r'(\d+)\s*(hour|minute|second)?', self.errmsg)])
- self.setWait(wait_time, True)
- self.wait()
+ self.wait(wait_time, True)
elif 'captcha' in self.errmsg:
self.invalidCaptcha()
elif 'premium' in self.errmsg and 'require' in self.errmsg:
self.fail("File can be downloaded by premium users only")
elif 'limit' in self.errmsg:
- self.setWait(3600, True)
- self.wait()
+ self.wait(1 * 60 * 60, True)
self.retry(25)
elif 'countdown' in self.errmsg or 'Expired' in self.errmsg:
self.retry()