Unverified Commit 08b57c67 authored by Kasper Seweryn's avatar Kasper Seweryn 🥞
Browse files

Fix production env var checks

parent 43f609b4
...@@ -590,7 +590,7 @@ export default { ...@@ -590,7 +590,7 @@ export default {
) )
}, },
production () { production () {
return import.meta.env.NODE_ENV === 'production' return import.meta.env.PROD
} }
}, },
watch: { watch: {
......
...@@ -21,7 +21,7 @@ import globals from '@/components/globals' // eslint-disable-line ...@@ -21,7 +21,7 @@ import globals from '@/components/globals' // eslint-disable-line
import './registerServiceWorker' import './registerServiceWorker'
import '@/semantic' import '@/semantic'
logger.default.info('Loading environment:', import.meta.env.NODE_ENV) logger.default.info('Loading environment:', import.meta.env.MODE)
logger.default.debug('Environment variables:', import.meta.env) logger.default.debug('Environment variables:', import.meta.env)
sync(store, router) sync(store, router)
......
...@@ -4,7 +4,7 @@ import { register } from 'register-service-worker' ...@@ -4,7 +4,7 @@ import { register } from 'register-service-worker'
import store from './store' import store from './store'
if (import.meta.env.NODE_ENV === 'production') { if (import.meta.env.PROD) {
register(`${import.meta.env.BASE_URL}service-worker.js`, { register(`${import.meta.env.BASE_URL}service-worker.js`, {
registrationOptions: { scope: '/' }, registrationOptions: { scope: '/' },
ready () { ready () {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment