diff --git a/src/common/components/templates/Space.tsx b/src/common/components/templates/Space.tsx
index a9bdfc59..94d2cf63 100644
--- a/src/common/components/templates/Space.tsx
+++ b/src/common/components/templates/Space.tsx
@@ -97,15 +97,9 @@ export default function Space({
: LayoutFidgets["grid"];
return (
- <>
+
-
+
{!isUndefined(profile) ? (
{profile}
@@ -126,6 +120,6 @@ export default function Space({
/>
- >
+
);
}
diff --git a/src/constants/app.ts b/src/constants/app.ts
index 112b4b3f..1a6cb72b 100644
--- a/src/constants/app.ts
+++ b/src/constants/app.ts
@@ -1,7 +1,10 @@
export const WEBSITE_URL =
process.env.NEXT_PUBLIC_VERCEL_ENV === "preview"
- ? `https://${process.env.NEXT_PUBLIC_VERCEL_BRANCH_URL}`
+ ? typeof window !== "undefined"
+ ? window.location.origin
+ : `https://${process.env.NEXT_PUBLIC_VERCEL_BRANCH_URL}`
: process.env.NEXT_PUBLIC_URL;
+
export const APP_FID = process.env.NEXT_PUBLIC_APP_FID
? Number(process.env.NEXT_PUBLIC_APP_FID)
: undefined;
diff --git a/src/pages/_app.tsx b/src/pages/_app.tsx
index 2e6cd974..5e70f26c 100644
--- a/src/pages/_app.tsx
+++ b/src/pages/_app.tsx
@@ -19,10 +19,7 @@ const sidebarLayout = (page: React.ReactElement) => {
return (
<>