From 12e52255255786f7a37e5dc8754e1feef6354691 Mon Sep 17 00:00:00 2001 From: JunichiSugiura Date: Tue, 12 Nov 2024 10:16:43 +0100 Subject: [PATCH] Fix posthog env --- packages/profile/.env.development | 4 ++-- packages/profile/.env.production | 4 ++-- packages/profile/src/components/context/provider.tsx | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/profile/.env.development b/packages/profile/.env.development index 1c3c4311a..361764ed7 100644 --- a/packages/profile/.env.development +++ b/packages/profile/.env.development @@ -1,5 +1,5 @@ VITE_CARTRIDGE_API_URL="http://localhost:8000" VITE_KEYCHAIN_URL="http://localhost:3001" VITE_RPC_SEPOLIA="http://localhost:8001/x/starknet/sepolia" -NEXT_PUBLIC_POSTHOG_KEY=phc_UWaJajNQ00PjHhveZ81SJ2zVtBicKrzewdZHGiyavQQ -NEXT_PUBLIC_POSTHOG_HOST=https://profile.cartridge.gg/ingest +VITE_POSTHOG_KEY=phc_UWaJajNQ00PjHhveZ81SJ2zVtBicKrzewdZHGiyavQQ +VITE_POSTHOG_HOST=https://profile.cartridge.gg/ingest diff --git a/packages/profile/.env.production b/packages/profile/.env.production index b2224a916..292a30d28 100644 --- a/packages/profile/.env.production +++ b/packages/profile/.env.production @@ -1,5 +1,5 @@ VITE_CARTRIDGE_API_URL="https://api.cartridge.gg" VITE_KEYCHAIN_URL="https://x.cartridge.gg" VITE_RPC_SEPOLIA="https://api.cartridge.gg/x/starknet/sepolia" -NEXT_PUBLIC_POSTHOG_KEY=phc_UWaJajNQ00PjHhveZ81SJ2zVtBicKrzewdZHGiyavQQ -NEXT_PUBLIC_POSTHOG_HOST=https://profile.cartridge.gg/ingest \ No newline at end of file +VITE_POSTHOG_KEY=phc_UWaJajNQ00PjHhveZ81SJ2zVtBicKrzewdZHGiyavQQ +VITE_POSTHOG_HOST=https://profile.cartridge.gg/ingest diff --git a/packages/profile/src/components/context/provider.tsx b/packages/profile/src/components/context/provider.tsx index dd3f09a81..f8eccf896 100644 --- a/packages/profile/src/components/context/provider.tsx +++ b/packages/profile/src/components/context/provider.tsx @@ -10,8 +10,8 @@ import posthog from "posthog-js"; import { PostHogProvider } from "posthog-js/react"; if (typeof window !== "undefined") { - posthog.init(process.env.NEXT_PUBLIC_POSTHOG_KEY!, { - api_host: process.env.NEXT_PUBLIC_POSTHOG_HOST, + posthog.init(process.env.VITE_POSTHOG_KEY!, { + api_host: process.env.VITE_POSTHOG_HOST, person_profiles: "always", enable_recording_console_log: true, loaded: (posthog) => {