Skip to content

Commit

Permalink
Fixes LoginButton for SSR (#9880)
Browse files Browse the repository at this point in the history
* test

* add changeset

* test

* test

* test

* fix

* add changeset

* add changeset

---------

Co-authored-by: gradio-pr-bot <[email protected]>
  • Loading branch information
dawoodkhan82 and gradio-pr-bot authored Nov 1, 2024
1 parent d407c00 commit 120198f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/silver-planes-guess.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"gradio": patch
---

fix:Fixes LoginButton for SSR
4 changes: 3 additions & 1 deletion gradio/routes.py
Original file line number Diff line number Diff line change
Expand Up @@ -364,10 +364,12 @@ async def conditional_routing_middleware(
getattr(blocks, "node_process", None) is not None
and blocks.node_port is not None
and not path.startswith("/gradio_api")
and path not in ["/config", "/login", "/favicon.ico"]
and path not in ["/config", "/favicon.ico"]
and not path.startswith("/theme")
and not path.startswith("/svelte")
and not path.startswith("/static")
and not path.startswith("/login")
and not path.startswith("/logout")
):
if App.app_port is None:
App.app_port = request.url.port or int(
Expand Down

0 comments on commit 120198f

Please sign in to comment.