From 3756b65256840e9bef6c277b73ddce977427800e Mon Sep 17 00:00:00 2001 From: schroda <50052685+schroda@users.noreply.github.com> Date: Sat, 23 Dec 2023 15:15:03 +0100 Subject: [PATCH] Correctly check for dev env (#509) --- src/App.tsx | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/App.tsx b/src/App.tsx index cd44cc8137..7e56579875 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -11,7 +11,6 @@ import CssBaseline from '@mui/material/CssBaseline'; import React, { useLayoutEffect } from 'react'; import { Navigate, Route, Routes, useLocation } from 'react-router-dom'; import { loadErrorMessages, loadDevMessages } from '@apollo/client/dev'; -import { __DEV__ } from '@apollo/client/utilities/globals'; import { AppContext } from '@/components/context/AppContext'; import { Browse } from '@/screens/Browse'; import { DownloadQueue } from '@/screens/DownloadQueue'; @@ -37,7 +36,7 @@ import { ServerSettings } from '@/screens/settings/ServerSettings.tsx'; import { WebUISettings } from '@/screens/settings/WebUISettings.tsx'; import { ServerUpdateChecker } from '@/components/settings/ServerUpdateChecker.tsx'; -if (__DEV__) { +if (process.env.NODE_ENV !== 'production') { // Adds messages only in a dev environment loadDevMessages(); loadErrorMessages();