diff options
author | jansohn <jansohn@users.noreply.github.com> | 2015-10-02 10:09:26 +0200 |
---|---|---|
committer | jansohn <jansohn@users.noreply.github.com> | 2015-10-02 10:09:26 +0200 |
commit | 3a08656c5665f4b8db98744fb323e64b8630e084 (patch) | |
tree | 28f9f62ffc57888b76ca32540dbf5af3a4cfc8d0 /module/plugins/hooks/Captcha9Kw.py | |
parent | Merge pull request #1 from pyload/stable (diff) | |
parent | [Account] Improve parse_traffic method + code cosmetics (diff) | |
download | pyload-3a08656c5665f4b8db98744fb323e64b8630e084.tar.xz |
Merge pull request #2 from pyload/stable
sync with stable
Diffstat (limited to 'module/plugins/hooks/Captcha9Kw.py')
-rw-r--r-- | module/plugins/hooks/Captcha9Kw.py | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/module/plugins/hooks/Captcha9Kw.py b/module/plugins/hooks/Captcha9Kw.py index 2e2685978..656497dd6 100644 --- a/module/plugins/hooks/Captcha9Kw.py +++ b/module/plugins/hooks/Captcha9Kw.py @@ -78,7 +78,6 @@ class Captcha9Kw(Hook): 'cpm' : self.get_config('captchapermin')} for opt in str(self.get_config('hoster_options').split('|')): - details = map(str.strip, opt.split(':')) if not details or details[0].lower() is not pluginname.lower(): @@ -149,6 +148,7 @@ class Captcha9Kw(Hook): time.sleep(5) else: break + else: self.log_debug("Could not send request: %s" % res) result = None @@ -184,6 +184,7 @@ class Captcha9Kw(Hook): break time.sleep(10) + else: self.fail(_("Too many captchas in queue")) @@ -196,9 +197,9 @@ class Captcha9Kw(Hook): for d in details: hosteroption = d.split("=") - if len(hosteroption) > 1 \ - and hosteroption[0].lower() == "timeout" \ - and hosteroption[1].isdigit(): + if len(hosteroption) > 1 and \ + hosteroption[0].lower() == "timeout" and \ + hosteroption[1].isdigit(): timeout = int(hosteroption[1]) break |