From 12f81acbf25b4338897c540ec6b6d98c5b5db6c8 Mon Sep 17 00:00:00 2001 From: JBB0807 <104856796+JBB0807@users.noreply.github.com> Date: Fri, 2 May 2025 18:34:20 -0700 Subject: [PATCH] bug fixes for fly server --- .env | 4 ++-- .env.development | 2 ++ src/components/Navbar.jsx | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) create mode 100644 .env.development diff --git a/.env b/.env index 7dc9c2c..ddf3a43 100644 --- a/.env +++ b/.env @@ -1,2 +1,2 @@ -VITE_AUTH_URL="http://localhost:8080" -#VITE_AUTH_URL="https://byte-camp-auth-service.fly.dev" \ No newline at end of file +#VITE_AUTH_URL="http://localhost:8080" +VITE_AUTH_URL="https://byte-camp-auth-service.fly.dev" \ No newline at end of file diff --git a/.env.development b/.env.development new file mode 100644 index 0000000..7dc9c2c --- /dev/null +++ b/.env.development @@ -0,0 +1,2 @@ +VITE_AUTH_URL="http://localhost:8080" +#VITE_AUTH_URL="https://byte-camp-auth-service.fly.dev" \ No newline at end of file diff --git a/src/components/Navbar.jsx b/src/components/Navbar.jsx index 02b1e5e..537cb27 100644 --- a/src/components/Navbar.jsx +++ b/src/components/Navbar.jsx @@ -13,7 +13,7 @@ const Navbar = () => { const menuRef = useRef(null); async function handleLogout() { - window.open("http://localhost:8080/auth/logout", "_self"); + window.open(`${authUrl}/auth/logout`, "_self"); }; useEffect(() => {