Commit fe6cc8c2 by 江名洋

fix: 修复未登录重定向路径为相对路径

1 parent fe674647
Showing 1 changed file with 1 additions and 1 deletions
......@@ -145,7 +145,7 @@ def _page_handler(template_name: str, require_auth: bool = True):
user = AuthService.get_current_user_from_token(db, token)
if not user:
# 未登录重定向到登录页
return RedirectResponse(url="/login", status_code=302)
return RedirectResponse(url="./login", status_code=302)
return templates.TemplateResponse(request=request, name=template_name, context={})
return handler
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!