diff options
author | 2015-07-24 16:11:58 +0200 | |
---|---|---|
committer | 2015-07-24 16:11:58 +0200 | |
commit | 761ca5c66e07559925ebbdbc6531f9ca658b12ce (patch) | |
tree | bbdf0f330be882877a28366a852c90711c709338 /module/plugins/hooks/DeathByCaptcha.py | |
parent | Hotfixes (2) (diff) | |
download | pyload-761ca5c66e07559925ebbdbc6531f9ca658b12ce.tar.xz |
Code cosmetics
Diffstat (limited to 'module/plugins/hooks/DeathByCaptcha.py')
-rw-r--r-- | module/plugins/hooks/DeathByCaptcha.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/module/plugins/hooks/DeathByCaptcha.py b/module/plugins/hooks/DeathByCaptcha.py index baf73d6b8..c27db422b 100644 --- a/module/plugins/hooks/DeathByCaptcha.py +++ b/module/plugins/hooks/DeathByCaptcha.py @@ -93,11 +93,11 @@ class DeathByCaptcha(Hook): raise DeathByCaptchaException(str(res)) except BadHeader, e: - if 403 == e.code: + if 403 is e.code: raise DeathByCaptchaException('not-logged-in') - elif 413 == e.code: + elif 413 is e.code: raise DeathByCaptchaException('invalid-captcha') - elif 503 == e.code: + elif 503 is e.code: raise DeathByCaptchaException('service-overload') elif e.code in (400, 405): raise DeathByCaptchaException('invalid-request') @@ -192,7 +192,7 @@ class DeathByCaptcha(Hook): def captcha_invalid(self, task): - if task.data['service'] == self.__name__ and "ticket" in task.data: + if task.data['service'] is self.__name__ and "ticket" in task.data: try: res = self.api_response("captcha/%d/report" % task.data['ticket'], True) |