summaryrefslogtreecommitdiffstats
path: root/module/plugins/hoster/RyushareCom.py
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@gmail.com> 2014-10-03 09:06:05 +0200
committerGravatar Walter Purcaro <vuolter@gmail.com> 2014-10-03 09:09:53 +0200
commit23ae563604dca1dae262fbc598154b99b2f1eae8 (patch)
tree1540b988d133c052bf0d6e7f26f02324db6f944a /module/plugins/hoster/RyushareCom.py
parent[MovReelCom] Fixed LINK_PATTERN (diff)
downloadpyload-23ae563604dca1dae262fbc598154b99b2f1eae8.tar.xz
Update plugins after CaptchaService and XFileSharingPro changes
Diffstat (limited to 'module/plugins/hoster/RyushareCom.py')
-rw-r--r--module/plugins/hoster/RyushareCom.py13
1 files changed, 6 insertions, 7 deletions
diff --git a/module/plugins/hoster/RyushareCom.py b/module/plugins/hoster/RyushareCom.py
index a24090cde..49fb2b07f 100644
--- a/module/plugins/hoster/RyushareCom.py
+++ b/module/plugins/hoster/RyushareCom.py
@@ -26,7 +26,6 @@ class RyushareCom(XFileSharingPro):
WAIT_PATTERN = r'You have to wait ((?P<hour>\d+) hour[s]?, )?((?P<min>\d+) minute[s], )?(?P<sec>\d+) second[s]'
LINK_PATTERN = r'<a href="([^"]+)">Click here to download<'
- SOLVEMEDIA_PATTERN = r'http:\/\/api\.solvemedia\.com\/papi\/challenge\.script\?k=(.*?)"'
def getDownloadLink(self):
@@ -57,13 +56,13 @@ class RyushareCom(XFileSharingPro):
self.retry()
for _ in xrange(5):
- m = re.search(self.SOLVEMEDIA_PATTERN, self.html)
- if m is None:
- self.parseError("Error parsing captcha")
-
- captchaKey = m.group(1)
captcha = SolveMedia(self)
- challenge, response = captcha.challenge(captchaKey)
+
+ captcha_key = captcha.detect_key()
+ if captcha_key is None:
+ self.parseError("SolveMedia key not found")
+
+ challenge, response = captcha.challenge(captcha_key)
inputs['adcopy_challenge'] = challenge
inputs['adcopy_response'] = response