From 394aba8794124be091c8ddcf6d387eda30051a22 Mon Sep 17 00:00:00 2001 From: lohxt1 Date: Wed, 16 Oct 2024 10:27:00 +0530 Subject: [PATCH] feat: moved posthog key to process env --- packages/bruno-app/.gitignore | 2 ++ .../bruno-app/src/components/Sidebar/GoldenEdition/index.js | 2 +- packages/bruno-app/src/providers/App/useTelemetry.js | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/packages/bruno-app/.gitignore b/packages/bruno-app/.gitignore index 1afc1f3a65..26d2023a39 100644 --- a/packages/bruno-app/.gitignore +++ b/packages/bruno-app/.gitignore @@ -32,3 +32,5 @@ yarn-error.log* # next.js .next/ out/ + +.env \ No newline at end of file diff --git a/packages/bruno-app/src/components/Sidebar/GoldenEdition/index.js b/packages/bruno-app/src/components/Sidebar/GoldenEdition/index.js index 4335bc2359..ac6acee68e 100644 --- a/packages/bruno-app/src/components/Sidebar/GoldenEdition/index.js +++ b/packages/bruno-app/src/components/Sidebar/GoldenEdition/index.js @@ -8,7 +8,7 @@ import StyledWrapper from './StyledWrapper'; import { useTheme } from 'providers/Theme/index'; let posthogClient = null; -const posthogApiKey = 'phc_7gtqSrrdZRohiozPMLIacjzgHbUlhalW1Bu16uYijMR'; +const posthogApiKey = process.env.NEXT_PUBLIC_POSTHOG_API_KEY; const getPosthogClient = () => { if (posthogClient) { return posthogClient; diff --git a/packages/bruno-app/src/providers/App/useTelemetry.js b/packages/bruno-app/src/providers/App/useTelemetry.js index 66bf5b0b1d..176a7505a4 100644 --- a/packages/bruno-app/src/providers/App/useTelemetry.js +++ b/packages/bruno-app/src/providers/App/useTelemetry.js @@ -13,7 +13,7 @@ import platformLib from 'platform'; import { uuid } from 'utils/common'; const { publicRuntimeConfig } = getConfig(); -const posthogApiKey = 'phc_7gtqSrrdZRohiozPMLIacjzgHbUlhalW1Bu16uYijMR'; +const posthogApiKey = process.env.NEXT_PUBLIC_POSTHOG_API_KEY; let posthogClient = null; const isPlaywrightTestRunning = () => {