From 1dfe2e62e87ceb5f8e23bfd5f887f8d7fd7862da Mon Sep 17 00:00:00 2001 From: Sampo Tawast Date: Tue, 22 Aug 2023 16:21:34 +0300 Subject: [PATCH] remove TS things from JS file --- frontend/shared/sentry-config.js | 41 ++++++++++++++++---------------- 1 file changed, 21 insertions(+), 20 deletions(-) diff --git a/frontend/shared/sentry-config.js b/frontend/shared/sentry-config.js index 1b0331b84d..b204f3290a 100644 --- a/frontend/shared/sentry-config.js +++ b/frontend/shared/sentry-config.js @@ -1,24 +1,25 @@ -import * as Sentry from "@sentry/nextjs"; +import * as Sentry from '@sentry/nextjs'; import maskGDPRData from 'shared/utils/mask-gdpr-data'; export default function sentryConfig() { Sentry.init({ - dsn: process.env.NEXT_PUBLIC_SENTRY_DSN || '', - environment: process.env.NEXT_PUBLIC_SENTRY_ENVIRONMENT || 'development', - attachStacktrace: true, - maxBreadcrumbs: Number(process.env.NEXT_PUBLIC_SENTRY_MAX_BREADCRUMBS) || 100, - // Adjust this value in production, or use tracesSampler for greater control - // @see https://develop.sentry.dev/sdk/performance/ - tracesSampleRate: 1, - beforeBreadcrumb(breadcrumb: Sentry.Breadcrumb) { - return { - ...breadcrumb, - message: maskGDPRData(breadcrumb.message), - data: maskGDPRData(breadcrumb.data), - }; - }, - beforeSend(event: Sentry.Event) { - return maskGDPRData(event); - }, - }) -}; \ No newline at end of file + dsn: process.env.NEXT_PUBLIC_SENTRY_DSN || '', + environment: process.env.NEXT_PUBLIC_SENTRY_ENVIRONMENT || 'development', + attachStacktrace: true, + maxBreadcrumbs: + Number(process.env.NEXT_PUBLIC_SENTRY_MAX_BREADCRUMBS) || 100, + // Adjust this value in production, or use tracesSampler for greater control + // @see https://develop.sentry.dev/sdk/performance/ + tracesSampleRate: 1, + beforeBreadcrumb(breadcrumb) { + return { + ...breadcrumb, + message: maskGDPRData(breadcrumb.message), + data: maskGDPRData(breadcrumb.data), + }; + }, + beforeSend(event) { + return maskGDPRData(event); + }, + }); +}