Fix network access for iPhone testing

- Add 192.168.101.111 to ALLOWED_HOSTS and CORS_ALLOWED_ORIGINS
- Update frontend env to use network IP for API
- Fix page redirect to wait for hydration
This commit is contained in:
Andrej Spielmann
2026-03-26 13:52:24 +01:00
parent b571509d41
commit e42f5e2315
2 changed files with 12 additions and 4 deletions
+4 -2
View File
@@ -7,15 +7,17 @@ import { Loader2 } from "lucide-react"
export default function HomePage() {
const router = useRouter()
const { token } = useAuth()
const { token, isHydrated } = useAuth()
useEffect(() => {
if (!isHydrated) return
if (token) {
router.push("/dashboard")
} else {
router.push("/login")
}
}, [token, router])
}, [token, isHydrated, router])
return (
<div className="min-h-screen flex items-center justify-center">