diff --git a/src/main.js b/src/main.js index 993a4aa..bd77f66 100644 --- a/src/main.js +++ b/src/main.js @@ -28,17 +28,17 @@ const Privacy = import('./components/Privacy.vue'); const Register = import('./components/Register.vue'); const Profile = import('./components/Profile.vue'); // -let routes = []; -if (config.baseurl && config.documentserver_key) { - routes = [ - { path: '/', component: Home }, - { path: '/imprint', component: Imprint }, - { path: '/privacy', component: Privacy }, - { path: '/register', component: Register }, - { path: '/profile', component: Profile } - ]; -} else { - routes = [ { path: '/', component: EnvError } ]; +let routes = [ { path: '/', component: EnvError } ]; +if (typeof config !== 'undefined') { + if (config.baseurl && config.documentserver_key) { + routes = [ + { path: '/', component: Home }, + { path: '/imprint', component: Imprint }, + { path: '/privacy', component: Privacy }, + { path: '/register', component: Register }, + { path: '/profile', component: Profile } + ]; + } } const router = createRouter({ history: createWebHistory(),