diff --git a/app/classes/web/panel_handler.py b/app/classes/web/panel_handler.py index 08dd1c85..a7e54974 100644 --- a/app/classes/web/panel_handler.py +++ b/app/classes/web/panel_handler.py @@ -80,9 +80,8 @@ class PanelHandler(BaseHandler): ) in self.controller.crafty_perms.list_defined_crafty_permissions(): argument = int( float( - nh3.clean( - self.get_argument(f"permission_{permission.name}", "0") - ) # pylint: disable=no-member + # pylint: disable=no-member + nh3.clean(self.get_argument(f"permission_{permission.name}", "0")) ) ) if argument: @@ -92,8 +91,9 @@ class PanelHandler(BaseHandler): q_argument = int( float( + # pylint: disable=no-member nh3.clean(self.get_argument(f"quantity_{permission.name}", "0")) - ) # pylint: disable=no-member + ) ) if q_argument: server_quantity[permission.name] = q_argument @@ -507,9 +507,9 @@ class PanelHandler(BaseHandler): template = "panel/dashboard.html" elif page == "server_detail": - subpage = nh3.clean( - self.get_argument("subpage", "") - ) # pylint: disable=no-member + # pylint: disable=no-member + subpage = nh3.clean(self.get_argument("subpage", "")) + # pylint: enable=no-member server_id = self.check_server_id() # load page the user was on last @@ -1368,9 +1368,9 @@ class PanelHandler(BaseHandler): template = "panel/panel_edit_user_apikeys.html" elif page == "remove_user": - user_id = nh3.clean( - self.get_argument("id", None) - ) # pylint: disable=no-member + # pylint: disable=no-member + user_id = nh3.clean(self.get_argument("id", None)) + # pylint: enable=no-member if ( not superuser diff --git a/app/classes/web/public_handler.py b/app/classes/web/public_handler.py index 101727eb..762d3fb1 100644 --- a/app/classes/web/public_handler.py +++ b/app/classes/web/public_handler.py @@ -29,12 +29,10 @@ class PublicHandler(BaseHandler): # self.clear_cookie("user_data") def get(self, page=None): - error = nh3.clean( - self.get_argument("error", "Invalid Login!") - ) # pylint: disable=no-member - error_msg = nh3.clean( - self.get_argument("error_msg", "") - ) # pylint: disable=no-member + # pylint: disable=no-member + error = nh3.clean(self.get_argument("error", "Invalid Login!")) + error_msg = nh3.clean(self.get_argument("error_msg", "")) + # pylint: enable=no-member page_data = { "version": self.helper.get_version_string(), @@ -91,12 +89,10 @@ class PublicHandler(BaseHandler): ) def post(self, page=None): - error = nh3.clean( - self.get_argument("error", "Invalid Login!") - ) # pylint: disable=no-member - error_msg = nh3.clean( - self.get_argument("error_msg", "") - ) # pylint: disable=no-member + # pylint: disable=no-member + error = nh3.clean(self.get_argument("error", "Invalid Login!")) + error_msg = nh3.clean(self.get_argument("error_msg", "")) + # pylint: enable=no-member page_data = { "version": self.helper.get_version_string(), @@ -116,10 +112,10 @@ class PublicHandler(BaseHandler): if self.request.query: next_page = "/login?" + self.request.query - entered_username = nh3.clean( - self.get_argument("username") - ) # pylint: disable=no-member + # pylint: disable=no-member + entered_username = nh3.clean(self.get_argument("username")) entered_password = self.get_argument("password") + # pylint: enable=no-member try: user_id = HelperUsers.get_user_id_by_name(entered_username.lower())