diff --git a/src/boot/init.ts b/src/boot/init.ts index e3ed67e..ab3db62 100644 --- a/src/boot/init.ts +++ b/src/boot/init.ts @@ -21,8 +21,8 @@ async function loadBaseUrl() { console.warn('Could not load BaseURL', e); } } - -class BackendError extends Error {} +// eslint-disable-next-line +class BackendError extends Error { } /** * Loading backend information @@ -68,8 +68,18 @@ export default boot(async ({ app, router }) => { // Handle errors from loading the backend information if (error instanceof BackendError || isAxiosError(error)) { router.isReady().finally(() => { - if (Platform.is.capacitor) void router.push({ name: 'setup_backend' }); - else void router.push({ name: 'offline', params: { refresh: 1 } }); + // if (Platform.is.capacitor) void router.push({ name: 'setup_backend' }); + if (Platform.is.capacitor) { + //void router.push({ name: 'setup_backend' }) + Notify.create({ + type: 'negative', + message: + 'Backend nicht erreichbar! Prüfe deine Internetverbindung oder probiere es später nochmal.', + timeout: 0, + icon: 'mdi-alert-circle-outline', + closeBtn: true, + }); + } else void router.push({ name: 'offline', params: { refresh: 1 } }); }); } else if (typeof error === 'string') { // Handle plugin not found errors