diff options
author | zoidberg10 <zoidberg@mujmail.cz> | 2012-10-20 09:30:04 +0200 |
---|---|---|
committer | zoidberg10 <zoidberg@mujmail.cz> | 2012-10-20 09:30:04 +0200 |
commit | 1b494bca9f442b3a8dd75818c68f41235dcdbdfe (patch) | |
tree | 133b30c975f6541b1a01fa289eebc5d8295b53ab /module/plugins/hoster/XFileSharingPro.py | |
parent | update CaptchaBrotherhood - closed #696, sharerapid.com (diff) | |
download | pyload-1b494bca9f442b3a8dd75818c68f41235dcdbdfe.tar.xz |
Diffstat (limited to 'module/plugins/hoster/XFileSharingPro.py')
-rw-r--r-- | module/plugins/hoster/XFileSharingPro.py | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/module/plugins/hoster/XFileSharingPro.py b/module/plugins/hoster/XFileSharingPro.py index ef559a56f..713198754 100644 --- a/module/plugins/hoster/XFileSharingPro.py +++ b/module/plugins/hoster/XFileSharingPro.py @@ -34,7 +34,7 @@ class XFileSharingPro(SimpleHoster): __name__ = "XFileSharingPro" __type__ = "hoster" __pattern__ = r"^unmatchable$" - __version__ = "0.12" + __version__ = "0.13" __description__ = """XFileSharingPro common hoster base""" __author_name__ = ("zoidberg") __author_mail__ = ("zoidberg@mujmail.cz") @@ -126,7 +126,7 @@ class XFileSharingPro(SimpleHoster): break else: - if captcha in self.err: + if self.errmsg and 'captcha' in self.errmsg: self.fail("No valid captcha code entered") else: self.fail("Download link not found") @@ -185,20 +185,20 @@ class XFileSharingPro(SimpleHoster): wait_time = sum([int(v) * {"hour": 3600, "minute": 60, "second": 1}[u] for v, u in re.findall('(\d+)\s*(hour|minute|second)?', self.errmsg)]) self.setWait(wait_time, True) self.wait() + 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.retry(25) - elif 'captcha' in self.errmsg: - self.invalidCaptcha() elif 'countdown' in self.errmsg or 'Expired session' in self.errmsg: self.retry(3) elif 'maintenance' in self.errmsg: self.tempOffline() elif 'download files up to' in self.errmsg: self.fail("File too large for free download") - elif 'requires premium' in self.errmsg: - self.fail("File can be downloaded by premium users only") else: self.fail(self.errmsg) @@ -211,9 +211,9 @@ class XFileSharingPro(SimpleHoster): for i in range(3): if not self.errmsg: self.checkErrors() - action, inputs = self.parseHtmlForm(self.FORM_PATTERN) + action, inputs = self.parseHtmlForm(input_names={"op": re.compile("^download")}) if not inputs: - action, inputs = self.parseHtmlForm("action=(''|\"\")") + action, inputs = self.parseHtmlForm(self.FORM_PATTERN) if not inputs: if self.errmsg: self.retry() |