Safetydance is not browser compat

This commit is contained in:
Johannes Zellner
2023-04-16 19:06:14 +02:00
parent 05065fca0e
commit f0f3525b3e
7 changed files with 40 additions and 38 deletions
+4 -2
View File
@@ -11,11 +11,13 @@ export default {
components: { ConfirmDialog },
data() {
return {
accessToken: localStorage.token || ''
};
},
mounted() {
if (!this.accessToken) window.location.href = '/';
if (!localStorage.token) {
if (import.meta.env.BASE_URL !== '/') window.location.href = '/';
else console.error('Set localStorage.token')
}
}
};