File tree Expand file tree Collapse file tree 1 file changed +17
-9
lines changed
Assets/Thirdweb/Core/Scripts Expand file tree Collapse file tree 1 file changed +17
-9
lines changed Original file line number Diff line number Diff line change @@ -67,15 +67,23 @@ internal async Task<string> Connect(WalletConnection walletConnection)
67
67
throw new UnityException ( "Smart wallet config is required for smart wallet connection method!" ) ;
68
68
if ( ActiveWallet ? . GetProvider ( ) != walletConnection . personalWallet )
69
69
{
70
- await Connect (
71
- new WalletConnection (
72
- provider : walletConnection . personalWallet ,
73
- chainId : walletConnection . chainId ,
74
- password : walletConnection . password ,
75
- email : walletConnection . email ,
76
- authOptions : walletConnection . authOptions
77
- )
78
- ) ;
70
+ try
71
+ {
72
+ await Connect (
73
+ new WalletConnection (
74
+ provider : walletConnection . personalWallet ,
75
+ chainId : walletConnection . chainId ,
76
+ password : walletConnection . password ,
77
+ email : walletConnection . email ,
78
+ authOptions : walletConnection . authOptions
79
+ )
80
+ ) ;
81
+ }
82
+ catch
83
+ {
84
+ ActiveWallet = null ;
85
+ throw ;
86
+ }
79
87
}
80
88
else
81
89
{
You can’t perform that action at this time.
0 commit comments