File tree Expand file tree Collapse file tree 1 file changed +13
-6
lines changed
Expand file tree Collapse file tree 1 file changed +13
-6
lines changed Original file line number Diff line number Diff line change @@ -98,7 +98,7 @@ type PoolsWithExtraRewardsList = Record<NetworkType, Array<SupportedToken>>;
9898const DEFAULT_POOLS_WITH_EXTRA_REWARDS : PoolsWithExtraRewardsList = {
9999 Mainnet : [ "sdcrvUSDV3" ] ,
100100 Arbitrum : [ ] ,
101- Optimism : [ "sdUSDCV3 " , "sdWETHV3" ] ,
101+ Optimism : [ "sdUSDC_eV3 " , "sdWETHV3" ] ,
102102 Base : [ ] ,
103103} ;
104104
@@ -197,16 +197,23 @@ export class GearboxRewardsApi {
197197 ] ,
198198 } ) ,
199199
200- ...tokenWithExtraRewards . map ( symbol =>
201- axios . get < MerkleXYZRewardsCampaignsResponse > (
200+ ...tokenWithExtraRewards . map ( symbol => {
201+ const addr = currentTokenData [ symbol ] ;
202+
203+ if ( ! addr )
204+ return ( async ( ) => {
205+ getAddress ( addr ) ;
206+ } ) ( ) ;
207+
208+ return axios . get < MerkleXYZRewardsCampaignsResponse > (
202209 MerkleXYZApi . getRewardsCampaignsUrl ( {
203210 params : {
204211 chainId,
205- mainParameter : getAddress ( currentTokenData [ symbol ] ) ,
212+ mainParameter : getAddress ( addr ) ,
206213 } ,
207214 } ) ,
208- ) ,
209- ) ,
215+ ) ;
216+ } ) ,
210217 ] ) ;
211218
212219 const mcResponse =
You can’t perform that action at this time.
0 commit comments