From 8c5a6f2fd4bceab37d39b615f39a15031ea2e92f Mon Sep 17 00:00:00 2001
From: Ajay Bura <32841439+ajbura@users.noreply.github.com>
Date: Mon, 9 Sep 2024 14:08:38 +0530
Subject: [PATCH] fix env mode check when registering sw

---
 src/index.tsx | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/index.tsx b/src/index.tsx
index 638d5fcf..805847f1 100644
--- a/src/index.tsx
+++ b/src/index.tsx
@@ -24,7 +24,7 @@ settings.applyTheme();
 // Register Service Worker
 if ('serviceWorker' in navigator) {
   const swUrl =
-    import.meta.env.MODE === 'prod'
+    import.meta.env.MODE === 'production'
       ? `${trimTrailingSlash(import.meta.env.BASE_URL)}/sw.js`
       : `/dev-sw.js?dev-sw`;