diff options
author | 2014-11-26 22:46:44 +0100 | |
---|---|---|
committer | 2014-11-26 22:46:44 +0100 | |
commit | f513f69f09b091f7c29f607d5c32ff8e35e8282a (patch) | |
tree | 58e77618449280c4ae1b1f6095d80a352ea82d31 /pyload/plugins/captcha/ReCaptcha.py | |
parent | Merge branch 'stable' into 0.4.10 (diff) | |
download | pyload-f513f69f09b091f7c29f607d5c32ff8e35e8282a.tar.xz |
Fix previous merge
Diffstat (limited to 'pyload/plugins/captcha/ReCaptcha.py')
-rw-r--r-- | pyload/plugins/captcha/ReCaptcha.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/pyload/plugins/captcha/ReCaptcha.py b/pyload/plugins/captcha/ReCaptcha.py index 4516b76de..c4054c29b 100644 --- a/pyload/plugins/captcha/ReCaptcha.py +++ b/pyload/plugins/captcha/ReCaptcha.py @@ -8,7 +8,7 @@ from pyload.plugins.internal.Captcha import Captcha class ReCaptcha(Captcha): __name__ = "ReCaptcha" __type__ = "captcha" - __version__ = "0.07" + __version__ = "0.08" __description__ = """ReCaptcha captcha service plugin""" __license__ = "GPLv3" @@ -48,15 +48,16 @@ class ReCaptcha(Captcha): raise TypeError(errmsg) js = self.plugin.req.load("http://www.google.com/recaptcha/api/challenge", get={'k': key}) - try: challenge = re.search("challenge : '(.+?)',", js).group(1) server = re.search("server : '(.+?)',", js).group(1) except: - self.plugin.error("ReCaptcha challenge pattern not found") + self.plugin.error(_("ReCaptcha challenge pattern not found")) result = self.result(server, challenge) + self.plugin.logDebug("ReCaptcha result: %s" % result, "challenge: %s" % challenge) + return challenge, result |