summaryrefslogtreecommitdiffstats
path: root/module/plugins/crypter/NCryptIn.py
diff options
context:
space:
mode:
Diffstat (limited to 'module/plugins/crypter/NCryptIn.py')
-rw-r--r--module/plugins/crypter/NCryptIn.py10
1 files changed, 4 insertions, 6 deletions
diff --git a/module/plugins/crypter/NCryptIn.py b/module/plugins/crypter/NCryptIn.py
index 32c9283f7..dddffbbf2 100644
--- a/module/plugins/crypter/NCryptIn.py
+++ b/module/plugins/crypter/NCryptIn.py
@@ -121,7 +121,7 @@ class NCryptIn(Crypter):
def get_package_info(self):
m = re.search(self.NAME_PATTERN, self.html)
- if m:
+ if m is not None:
name = folder = m.group('N').strip()
self.log_debug("Found name [%s] and folder [%s] in package info" % (name, folder))
else:
@@ -177,13 +177,11 @@ class NCryptIn(Crypter):
def handle_errors(self):
if self.protection_type == "password":
if "This password is invalid!" in self.cleaned_html:
- self.log_debug("Incorrect password, please set right password on 'Edit package' form and retry")
- self.fail(_("Incorrect password, please set right password on 'Edit package' form and retry"))
+ self.fail(_("Wrong password"))
if self.protection_type == "captcha":
- if "The securitycheck was wrong!" in self.cleaned_html:
- self.captcha.invalid()
- self.retry()
+ if "The securitycheck was wrong" in self.cleaned_html:
+ self.retry_captcha()
else:
self.captcha.correct()