Skip to content

Commit

Permalink
Fix root when user is unauthenticated so that login page appears co…
Browse files Browse the repository at this point in the history
…rrectly (#6042)

* fix

* add changeset

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
  • Loading branch information
abidlabs and gradio-pr-bot committed Oct 20, 2023
1 parent f2cd6cb commit e27997f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/puny-teeth-notice.md
@@ -0,0 +1,5 @@
---
"gradio": patch
---

fix:Fix `root` when user is unauthenticated so that login page appears correctly
2 changes: 1 addition & 1 deletion gradio/routes.py
Expand Up @@ -325,7 +325,7 @@ def main(request: fastapi.Request, user: str = Depends(get_current_user)):
"auth_required": True,
"auth_message": blocks.auth_message,
"space_id": app.get_blocks().space_id,
"root": root_path,
"root": route_utils.strip_url(root_path),
}

try:
Expand Down

0 comments on commit e27997f

Please sign in to comment.