File tree Expand file tree Collapse file tree 1 file changed +13
-9
lines changed
apps/dashboard/src/app/team/[team_slug]/[project_slug]/connect/account-abstraction/factories Expand file tree Collapse file tree 1 file changed +13
-9
lines changed Original file line number Diff line number Diff line change @@ -115,19 +115,23 @@ async function AsyncYourFactories(props: {
115
115
authToken : props . authToken ,
116
116
} ) ;
117
117
118
- const client = getThirdwebClient ( ) ;
118
+ const client = getThirdwebClient ( props . authToken ) ;
119
119
120
120
const factories = (
121
121
await Promise . all (
122
122
deployedContracts . map ( async ( c ) => {
123
- const contract = getContract ( {
124
- // eslint-disable-next-line no-restricted-syntax
125
- chain : defineChain ( Number ( c . chainId ) ) ,
126
- address : c . contractAddress ,
127
- client,
128
- } ) ;
129
- const m = await getCompilerMetadata ( contract ) ;
130
- return m . name . indexOf ( "AccountFactory" ) > - 1 ? c : null ;
123
+ try {
124
+ const contract = getContract ( {
125
+ // eslint-disable-next-line no-restricted-syntax
126
+ chain : defineChain ( Number ( c . chainId ) ) ,
127
+ address : c . contractAddress ,
128
+ client,
129
+ } ) ;
130
+ const m = await getCompilerMetadata ( contract ) ;
131
+ return m . name . indexOf ( "AccountFactory" ) > - 1 ? c : null ;
132
+ } catch {
133
+ return null ;
134
+ }
131
135
} ) ,
132
136
)
133
137
) . filter ( ( f ) => f !== null ) ;
You can’t perform that action at this time.
0 commit comments