summaryrefslogtreecommitdiffstats
path: root/module/plugins/hooks/Captcha9Kw.py
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@users.noreply.github.com> 2015-10-01 04:55:17 +0200
committerGravatar Walter Purcaro <vuolter@users.noreply.github.com> 2015-10-01 04:55:17 +0200
commit25d5726d4953b93a2e286fd6af8d4ead20670ba6 (patch)
tree9d38f6942af2fadc094a75dd43699051f356b4d7 /module/plugins/hooks/Captcha9Kw.py
parent[AntiVirus] Folder support (diff)
downloadpyload-25d5726d4953b93a2e286fd6af8d4ead20670ba6.tar.xz
A lot of plugin code cosmetics
Diffstat (limited to 'module/plugins/hooks/Captcha9Kw.py')
-rw-r--r--module/plugins/hooks/Captcha9Kw.py9
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