From 869c252088605037ed0607dd8ea6a663b16bdf07 Mon Sep 17 00:00:00 2001 From: Mark Stacey Date: Tue, 28 Jul 2020 16:59:47 -0300 Subject: [PATCH] Disable Sentry in development (#9095) In a non-production environment, Sentry was configured to send error reports to a "test" MetaMask project. It will still do this during e2e tests, but in development Sentry is now disabled completely. In practice this was never useful in development. --- app/scripts/lib/setupSentry.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/scripts/lib/setupSentry.js b/app/scripts/lib/setupSentry.js index 04c4b5014..9eca2ef5b 100644 --- a/app/scripts/lib/setupSentry.js +++ b/app/scripts/lib/setupSentry.js @@ -72,7 +72,9 @@ export const SENTRY_STATE = { export default function setupSentry ({ release, getState }) { let sentryTarget - if (METAMASK_DEBUG || process.env.IN_TEST) { + if (METAMASK_DEBUG) { + return + } else if (process.env.IN_TEST) { console.log(`Setting up Sentry Remote Error Reporting for '${METAMASK_ENVIRONMENT}': SENTRY_DSN_DEV`) sentryTarget = SENTRY_DSN_DEV } else {