diff --git a/app/classes/web/base_handler.py b/app/classes/web/base_handler.py index ca39d199..04b0bd3a 100644 --- a/app/classes/web/base_handler.py +++ b/app/classes/web/base_handler.py @@ -32,7 +32,8 @@ class BaseHandler(tornado.web.RequestHandler): def autobleach(self, name, text): for r in self.redactables: if r in name: - logger.debug("Auto-bleaching {}: {}".format(name, "[**REDACTED* c,mmvkkkkkkkkkkkkkkkkkkkkkkkkn*]")) + logger.debug("Auto-bleaching {}: {}".format(name, "[**REDACTED**]")) + break else: logger.debug("Auto-bleaching {}: {}".format(name, text)) if type(text) in self.nobleach: diff --git a/app/classes/web/panel_handler.py b/app/classes/web/panel_handler.py index 7966be48..65347e33 100644 --- a/app/classes/web/panel_handler.py +++ b/app/classes/web/panel_handler.py @@ -504,8 +504,8 @@ class PanelHandler(BaseHandler): username = bleach.clean(self.get_argument('username', None)) password0 = bleach.clean(self.get_argument('password0', None)) password1 = bleach.clean(self.get_argument('password1', None)) - enabled = int(float(bleach.clean(self.get_argument('enabled'), '0'))) - regen_api = int(float(bleach.clean(self.get_argument('regen_api', '0')))) + enabled = int(float(self.get_argument('enabled', '0'))) + regen_api = int(float(self.get_argument('regen_api', '0'))) if not exec_user['superuser']: self.redirect("/panel/error?error=Unauthorized access: not superuser") @@ -556,7 +556,7 @@ class PanelHandler(BaseHandler): username = bleach.clean(self.get_argument('username', None)) password0 = bleach.clean(self.get_argument('password0', None)) password1 = bleach.clean(self.get_argument('password1', None)) - enabled = int(float(bleach.clean(self.get_argument('enabled'), '0'))) + enabled = int(float(self.get_argument('enabled', '0'))) if not exec_user['superuser']: self.redirect("/panel/error?error=Unauthorized access: not superuser") @@ -566,7 +566,7 @@ class PanelHandler(BaseHandler): return else: # does this user id exist? - if db_helper.get_userid_by_name(username) is not None: + if db_helper.get_user_id_by_name(username) is not None: self.redirect("/panel/error?error=User exists") return