fix post hog on app.infisical frontend

This commit is contained in:
Maidul Islam
2024-07-06 17:44:53 -04:00
parent d2759ea378
commit 3ba90cc42d
2 changed files with 3 additions and 3 deletions

View File

@@ -10,7 +10,7 @@ export const initPostHog = () => {
try {
if (typeof window !== "undefined") {
// @ts-ignore
if (ENV === "production" && TELEMETRY_CAPTURING_ENABLED === "true") {
if (ENV === "production" && TELEMETRY_CAPTURING_ENABLED === true) {
posthog.init(POSTHOG_API_KEY, {
api_host: POSTHOG_HOST
});

View File

@@ -13,7 +13,7 @@ class Capturer {
}
capture(item: string) {
if (ENV === "production" && TELEMETRY_CAPTURING_ENABLED === "true") {
if (ENV === "production" && TELEMETRY_CAPTURING_ENABLED === true) {
try {
this.api.capture(item);
} catch (error) {
@@ -23,7 +23,7 @@ class Capturer {
}
identify(id: string, email?: string) {
if (ENV === "production" && TELEMETRY_CAPTURING_ENABLED === "true") {
if (ENV === "production" && TELEMETRY_CAPTURING_ENABLED === true) {
try {
this.api.identify(id, {
email: email