This repository was archived by the owner on Sep 4, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +2
-24
lines changed Expand file tree Collapse file tree 2 files changed +2
-24
lines changed Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ void Update()
22
22
public async void Login ( )
23
23
{
24
24
Magic magic = Magic . Instance ;
25
- var token = await magic . Auth . LoginWithMagicLink ( "jerry+unity @magic.link") ;
25
+ var token = await magic . Auth . LoginWithEmailOtp ( "hiro @magic.link") ;
26
26
result . text = $ "token { token } ";
27
27
}
28
28
Original file line number Diff line number Diff line change @@ -11,14 +11,6 @@ internal AuthModule(RpcProvider provider) : base(provider)
11
11
Provider = provider ;
12
12
}
13
13
14
- public async Task < string > LoginWithMagicLink ( string email , bool showUI = true )
15
- {
16
- var config = new LoginWithMagicLinkConfiguration ( email , showUI ) ;
17
- return await SendToProviderWithConfig < LoginWithMagicLinkConfiguration , string > ( config ,
18
- nameof ( AuthMethod . magic_auth_login_with_magic_link )
19
- ) ;
20
- }
21
-
22
14
public async Task < string > LoginWithSms ( string phoneNumber )
23
15
{
24
16
var config = new LoginWithSmsConfiguration ( phoneNumber ) ;
@@ -35,19 +27,6 @@ public async Task<string> LoginWithEmailOtp(string email)
35
27
}
36
28
37
29
38
- [ Serializable ]
39
- internal class LoginWithMagicLinkConfiguration : BaseConfiguration
40
- {
41
- public bool showUI ;
42
- public string email ;
43
-
44
- public LoginWithMagicLinkConfiguration ( string email , bool showUI = true )
45
- {
46
- this . showUI = showUI ;
47
- this . email = email ;
48
- }
49
- }
50
-
51
30
[ Serializable ]
52
31
internal class LoginWithSmsConfiguration : BaseConfiguration
53
32
{
@@ -74,8 +53,7 @@ public LoginWithEmailOtpConfiguration(string email)
74
53
75
54
internal enum AuthMethod
76
55
{
77
- magic_auth_login_with_magic_link ,
78
56
magic_auth_login_with_sms ,
79
57
magic_auth_login_with_email_otp
80
58
}
81
- }
59
+ }
You can’t perform that action at this time.
0 commit comments