summaryrefslogtreecommitdiffstats
path: root/module/plugins/hoster/BitshareCom.py
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@gmail.com> 2014-10-23 00:50:23 +0200
committerGravatar Walter Purcaro <vuolter@gmail.com> 2014-10-23 00:50:23 +0200
commit7b67f68c1636014fe02286da71bdc6c13dc3eeee (patch)
treefce6a94fd3091c6f917acafcc53e71bd08097d5c /module/plugins/hoster/BitshareCom.py
parent[XFSPAccount] Better HOSTER_URL (diff)
downloadpyload-7b67f68c1636014fe02286da71bdc6c13dc3eeee.tar.xz
Simplify captcha challenge calls
Diffstat (limited to 'module/plugins/hoster/BitshareCom.py')
-rw-r--r--module/plugins/hoster/BitshareCom.py6
1 files changed, 1 insertions, 5 deletions
diff --git a/module/plugins/hoster/BitshareCom.py b/module/plugins/hoster/BitshareCom.py
index 9d2a23625..fe2ff0be6 100644
--- a/module/plugins/hoster/BitshareCom.py
+++ b/module/plugins/hoster/BitshareCom.py
@@ -113,14 +113,10 @@ class BitshareCom(SimpleHoster):
if captcha == 1:
self.logDebug("File is captcha protected")
recaptcha = ReCaptcha(self)
- captcha_key = recaptcha.detect_key()
- if captcha_key is None:
- self.error("ReCaptcha captcha key not found")
# Try up to 3 times
for i in xrange(3):
- self.logDebug("Resolving ReCaptcha with key [%s], round %d" % (captcha_key, i + 1))
- challenge, code = recaptcha.challenge(captcha_key)
+ challenge, code = recaptcha.challenge()
response = self.load("http://bitshare.com/files-ajax/" + self.file_id + "/request.html",
post={"request": "validateCaptcha", "ajaxid": self.ajaxid,
"recaptcha_challenge_field": challenge, "recaptcha_response_field": code})