summaryrefslogtreecommitdiffstats
path: root/module/plugins/hooks/BypassCaptcha.py
diff options
context:
space:
mode:
Diffstat (limited to 'module/plugins/hooks/BypassCaptcha.py')
-rw-r--r--module/plugins/hooks/BypassCaptcha.py17
1 files changed, 4 insertions, 13 deletions
diff --git a/module/plugins/hooks/BypassCaptcha.py b/module/plugins/hooks/BypassCaptcha.py
index cf8754dae..bd19fe953 100644
--- a/module/plugins/hooks/BypassCaptcha.py
+++ b/module/plugins/hooks/BypassCaptcha.py
@@ -4,7 +4,7 @@ from pycurl import FORM_FILE, LOW_SPEED_TIME
from module.network.HTTPRequest import BadHeader
from module.network.RequestFactory import getURL, getRequest
-from module.plugins.Hook import Hook, threaded
+from module.plugins.Addon import Addon, threaded
class BypassCaptchaException(Exception):
@@ -25,13 +25,13 @@ class BypassCaptchaException(Exception):
return "<BypassCaptchaException %s>" % self.err
-class BypassCaptcha(Hook):
+class BypassCaptcha(Addon):
__name__ = "BypassCaptcha"
__type__ = "hook"
__version__ = "0.06"
__config__ = [("force", "bool", "Force BC even if client is connected", False),
- ("passkey", "password", "Passkey", "")]
+ ("passkey", "password", "Passkey", "")]
__description__ = """Send captchas to BypassCaptcha.com"""
__license__ = "GPLv3"
@@ -47,15 +47,6 @@ class BypassCaptcha(Hook):
GETCREDITS_URL = "http://bypasscaptcha.com/ex_left.php"
- #@TODO: Remove in 0.4.10
- def initPeriodical(self):
- pass
-
-
- def setup(self):
- self.info = {} #@TODO: Remove in 0.4.10
-
-
def getCredits(self):
res = getURL(self.GETCREDITS_URL, post={"key": self.getConfig("passkey")})
@@ -98,7 +89,7 @@ class BypassCaptcha(Hook):
self.logError(_("Could not send response"), e)
- def newCaptchaTask(self, task):
+ def captchaTask(self, task):
if "service" in task.data:
return False