summaryrefslogtreecommitdiffstats
path: root/module/plugins/hooks
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@gmail.com> 2014-11-09 02:44:07 +0100
committerGravatar Walter Purcaro <vuolter@gmail.com> 2014-11-09 02:44:07 +0100
commitd6ef06aa8f1e2de97cf22e6895b631da0a8bb816 (patch)
treec9d96b3e343e358863cefe2f14a70cad12435871 /module/plugins/hooks
parent[Checksum] Don't use b'' (diff)
downloadpyload-d6ef06aa8f1e2de97cf22e6895b631da0a8bb816.tar.xz
[Captcha9kw] Fix a couple of typo
Diffstat (limited to 'module/plugins/hooks')
-rwxr-xr-xmodule/plugins/hooks/Captcha9kw.py27
1 files changed, 13 insertions, 14 deletions
diff --git a/module/plugins/hooks/Captcha9kw.py b/module/plugins/hooks/Captcha9kw.py
index 0b0de8ba5..af12ca830 100755
--- a/module/plugins/hooks/Captcha9kw.py
+++ b/module/plugins/hooks/Captcha9kw.py
@@ -17,7 +17,7 @@ from module.plugins.Hook import Hook
class Captcha9kw(Hook):
__name__ = "Captcha9kw"
__type__ = "hook"
- __version__ = "0.13"
+ __version__ = "0.14"
__config__ = [("activated", "bool", "Activated", True),
("force", "bool", "Force captcha resolving even if client is connected", True),
@@ -73,17 +73,17 @@ class Captcha9kw(Hook):
self.logDebug("%s: %s" % (task.captchaFile, data))
- option = {'min' : 2
- 'max' : 50
- 'phrase' : 0
- 'numeric' : 0
- 'case_sensitive' : 0
- 'math' : 0
- 'prio' : self.getConfig("prio")
- 'confirm' : self.getConfig("confirm")
- 'timeout' : min(max(self.getConfig("timeout") * 60, 300), 3999)
- 'selfsolve' : self.getConfig("selfsolve")
- 'cph' : self.getConfig("captchaperhour")
+ option = {'min' : 2,
+ 'max' : 50,
+ 'phrase' : 0,
+ 'numeric' : 0,
+ 'case_sensitive' : 0,
+ 'math' : 0,
+ 'prio' : self.getConfig("prio"),
+ 'confirm' : self.getConfig("confirm"),
+ 'timeout' : min(max(self.getConfig("timeout") * 60, 300), 3999),
+ 'selfsolve' : self.getConfig("selfsolve"),
+ 'cph' : self.getConfig("captchaperhour"),
'hoster_options' : self.getConfig("hoster_options").split(";")}
for opt in hoster_options:
@@ -209,6 +209,7 @@ class Captcha9kw(Hook):
def _captchaResponse(self, task, correct):
if "ticket" not in task.data:
+ self.logDebug(_("No CaptchaID for %s request (task: %s)" % type) % task)
return
type = "correct" if correct else "refund"
@@ -230,8 +231,6 @@ class Captcha9kw(Hook):
else:
self.logDebug(_("Could not send %s request: %s" % type) % res)
sleep(1)
- else:
- self.logDebug(_("No CaptchaID for %s request (task: %s)" % type) % task)
def captchaCorrect(self, task):