diff --git a/app/classes/shared/helpers.py b/app/classes/shared/helpers.py index 3f5bb8cc..18d34970 100644 --- a/app/classes/shared/helpers.py +++ b/app/classes/shared/helpers.py @@ -94,7 +94,7 @@ class Helpers: return True except Exception as err: return False - + @staticmethod def check_port(server_port): a_socket = socket.socket(socket.AF_INET, socket.SOCK_STREAM) @@ -653,9 +653,9 @@ class Helpers: @staticmethod def generate_tree(folder, output=""): - for file in sorted(os.scandir(folder), key=lambda e: e.name): - filename = html.escape(file.name) - rel = os.path.join(folder, filename) + for raw_filename in os.listdir(folder): + filename = html.escape(raw_filename) + rel = os.path.join(folder, raw_filename) if os.path.isdir(rel): output += \ """
  • diff --git a/app/classes/web/http_handler_page.py b/app/classes/web/http_handler_page.py index 8b9e9c90..3b5a6c81 100644 --- a/app/classes/web/http_handler_page.py +++ b/app/classes/web/http_handler_page.py @@ -25,11 +25,9 @@ class HTTPHandlerPage(BaseHandler): def get(self, page): url = self.request.full_url port = 443 - print(url) if url[len(url)-1] == '/': url = url.strip(url[len(url)-1]) url_list = url.split('/') - print(url_list) if url_list[0] != "": primary_url = url_list[0] + ":"+str(port)+"/" backup_url = url_list[0] + ":" +str(helper.get_setting["https_port"]) +"/"