diff --git a/apps/ledger-live-desktop/src/renderer/components/ConnectEnvsToSentry.tsx b/apps/ledger-live-desktop/src/renderer/components/ConnectEnvsToSentry.tsx index 99c1baa44ddb..bdfc64f29757 100644 --- a/apps/ledger-live-desktop/src/renderer/components/ConnectEnvsToSentry.tsx +++ b/apps/ledger-live-desktop/src/renderer/components/ConnectEnvsToSentry.tsx @@ -48,9 +48,13 @@ export const ConnectEnvsToSentry = () => { setSentryTagsEverywhere(tags); }; // We need to wait firebase to load the data and then we set once for all the tags - setTimeout(syncTheTags, 5000); + const timeout = setTimeout(syncTheTags, 5000); // We also try to regularly update them so we are sure to get the correct tags (as these are dynamic) - setInterval(syncTheTags, 60000); + const interval = setInterval(syncTheTags, 60000); + return () => { + clearTimeout(timeout); + clearInterval(interval); + }; }, []); return null; }; diff --git a/apps/ledger-live-mobile/index.js b/apps/ledger-live-mobile/index.js index fa9de57c856e..d2946b424a6b 100644 --- a/apps/ledger-live-mobile/index.js +++ b/apps/ledger-live-mobile/index.js @@ -24,7 +24,7 @@ import * as Sentry from "@sentry/react-native"; import Config from "react-native-config"; import VersionNumber from "react-native-version-number"; -import { getEnv } from "@ledgerhq/live-common/lib/env"; +import { getEnv } from "@ledgerhq/live-common/env"; import BackgroundRunnerService from "./services/BackgroundRunnerService"; import App, { routingInstrumentation } from "./src"; import { getEnabled } from "./src/components/HookSentry";