mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-23 00:08:23 +00:00
fall back to host
This commit is contained in:
@@ -201,9 +201,8 @@ async function findValidSession(
|
|||||||
}
|
}
|
||||||
|
|
||||||
function constructUrl(request: NextRequest, path: string) {
|
function constructUrl(request: NextRequest, path: string) {
|
||||||
// TODO: remove localhost
|
|
||||||
const forwardedHost =
|
const forwardedHost =
|
||||||
request.headers.get("x-zitadel-forward-host") ?? "http://localhost:8080";
|
request.headers.get("x-zitadel-forward-host") ?? request.headers.get("host");
|
||||||
const basePath = process.env.NEXT_PUBLIC_BASE_PATH || "";
|
const basePath = process.env.NEXT_PUBLIC_BASE_PATH || "";
|
||||||
return new URL(
|
return new URL(
|
||||||
`${basePath}${path}`,
|
`${basePath}${path}`,
|
||||||
|
Reference in New Issue
Block a user