@drax/identity-vue 0.7.21 → 0.7.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "access": "public"
5
5
  },
6
- "version": "0.7.21",
6
+ "version": "0.7.24",
7
7
  "type": "module",
8
8
  "main": "./src/index.ts",
9
9
  "module": "./src/index.ts",
@@ -66,5 +66,5 @@
66
66
  "vue-tsc": "^2.1.6",
67
67
  "vuetify": "^3.7.1"
68
68
  },
69
- "gitHead": "b334f8a21c0c263affa4dfb4afe3befb91bd110a"
69
+ "gitHead": "b2d08d46d4101ddee250448e949741ef7300fd13"
70
70
  }
@@ -37,9 +37,13 @@ export function useAuth() {
37
37
  }
38
38
 
39
39
  function logout() {
40
+ clearAuth()
41
+ router.push({name: 'Login'})
42
+ }
43
+
44
+ function clearAuth(){
40
45
  authSystem.logout()
41
46
  authStore.clearAuth()
42
- router.push({name: 'Login'})
43
47
  }
44
48
 
45
49
  function hasPermission(permission: string) {
@@ -54,7 +58,7 @@ export function useAuth() {
54
58
  if (tokenIsValid()) {
55
59
  return true
56
60
  } else {
57
- logout()
61
+ clearAuth()
58
62
  return false
59
63
  }
60
64
 
@@ -8,8 +8,8 @@ import UserApiKeyCrudPage from '../pages/crud/UserApiKeyCrudPage.vue'
8
8
 
9
9
  const routes = [
10
10
  {
11
- name: 'Login',
12
- path: '/login',
11
+ name: 'IdentityLogin',
12
+ path: '/identity-login',
13
13
  component: LoginPage,
14
14
  meta: {
15
15
  auth: false,