File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -17,7 +17,7 @@ type AllowAccessData = {
17
17
}
18
18
19
19
type Uid = string
20
-
20
+ type LoginWithAPIKEY = boolean
21
21
interface User {
22
22
email : Email
23
23
emailVerified : EmailVerified
@@ -35,6 +35,7 @@ export class UserStore extends VuexModule implements User {
35
35
emailVerified : EmailVerified = false
36
36
displayName : DisplayName = ''
37
37
uid : Uid = ''
38
+ isLoginWithAPIKEY : LoginWithAPIKEY = false
38
39
39
40
public get isAuthenticated ( ) : Promise < boolean > {
40
41
return ( async ( ) => {
@@ -52,6 +53,11 @@ export class UserStore extends VuexModule implements User {
52
53
this . uid = uid
53
54
}
54
55
56
+ @mutation
57
+ public setAuthModeIsAPIKEY ( isLoginWithAPIKEY : LoginWithAPIKEY ) {
58
+ this . isLoginWithAPIKEY = isLoginWithAPIKEY
59
+ }
60
+
55
61
@action
56
62
public async login ( ) {
57
63
const user = await Auth . currentAuthenticatedUser ( )
@@ -82,5 +88,6 @@ export class UserStore extends VuexModule implements User {
82
88
emailVerified : false ,
83
89
displayName : '' ,
84
90
} )
91
+ this . isLoginWithAPIKEY = false
85
92
}
86
93
}
You can’t perform that action at this time.
0 commit comments