diff --git a/resources/assets/vue/app.js b/resources/assets/vue/app.js index d9e2e465..52b09587 100644 --- a/resources/assets/vue/app.js +++ b/resources/assets/vue/app.js @@ -50,7 +50,8 @@ const app = new Vue({ store, created(){ this.routesGuard(); - if (!this.$store.getters.isAdmin && !('company_marking' in this.$store.getters.getDecodedAccessToken.user) && this.isProtectedRoute() && !this.isWithTokenRoute()) { + console.log(!this.$store.getters.isAdmin && !('company_marking' in this.$store.getters.getDecodedAccessToken.user) && this.isProtectedRoute()); + if (!this.$store.getters.isAdmin && !('company_marking' in this.$store.getters.getDecodedAccessToken.user) && this.isProtectedRoute()) { this.$store.dispatch('crudRequest', {endpoint: this.route('api.account.authentication.refresh'), method: 'get'}).then(response => { let success = response.ok; response.json().then(response => {