mirror of
https://github.com/cinnyapp/cinny.git
synced 2025-02-13 17:10:06 +00:00
fix env mode check when registering sw
This commit is contained in:
parent
024c8fad7f
commit
8c5a6f2fd4
|
@ -24,7 +24,7 @@ settings.applyTheme();
|
||||||
// Register Service Worker
|
// Register Service Worker
|
||||||
if ('serviceWorker' in navigator) {
|
if ('serviceWorker' in navigator) {
|
||||||
const swUrl =
|
const swUrl =
|
||||||
import.meta.env.MODE === 'prod'
|
import.meta.env.MODE === 'production'
|
||||||
? `${trimTrailingSlash(import.meta.env.BASE_URL)}/sw.js`
|
? `${trimTrailingSlash(import.meta.env.BASE_URL)}/sw.js`
|
||||||
: `/dev-sw.js?dev-sw`;
|
: `/dev-sw.js?dev-sw`;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue