9
0
mirror of https://github.com/donlon/cloudflare-error-page.git synced 2025-12-19 14:59:28 +00:00

miscellaneous fixes

This commit is contained in:
Anthony Donlon
2025-12-16 20:38:47 +08:00
parent 410968c2f0
commit feab26093c
5 changed files with 10 additions and 8 deletions

View File

@@ -8,7 +8,7 @@ from flask import (
)
root_dir = os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../')
res_folder = os.path.join(root_dir, 'editor/frontend/dist')
res_folder = os.path.join(root_dir, 'editor/web/dist')
bp = Blueprint('editor', __name__, url_prefix='/')

View File

@@ -39,7 +39,6 @@ def get_page_params(name: str) -> dict:
@bp.route('/', defaults={'name': 'default'})
@bp.route('/<path:name>')
def index(name: str):
name = os.path.basename(name) # keep only the base name
lower_name = name.lower()
if name != lower_name:
return redirect(lower_name)