File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
wormhole-connect/src/routes Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change 6
6
} from '@wormhole-foundation/wormhole-connect-sdk' ;
7
7
import { BigNumber } from 'ethers' ;
8
8
9
- import { CHAINS , ROUTES , TOKENS } from 'config' ;
9
+ import { CHAINS , ROUTES , TOKENS , TOKENS_ARR } from 'config' ;
10
10
import { TokenConfig , Route } from 'config/types' ;
11
11
import {
12
12
ParsedMessage ,
@@ -147,7 +147,8 @@ export class Operator {
147
147
) : Promise < TokenConfig [ ] > {
148
148
const supported : { [ key : string ] : TokenConfig } = { } ;
149
149
for ( const route of ROUTES ) {
150
- for ( const key in TOKENS ) {
150
+ for ( const token of TOKENS_ARR ) {
151
+ const { key } = token ;
151
152
const alreadySupported = supported [ key ] ;
152
153
if ( ! alreadySupported ) {
153
154
const isSupported = await this . isSupportedSourceToken (
@@ -173,7 +174,8 @@ export class Operator {
173
174
) : Promise < TokenConfig [ ] > {
174
175
const supported : { [ key : string ] : TokenConfig } = { } ;
175
176
for ( const route of ROUTES ) {
176
- for ( const key in TOKENS ) {
177
+ for ( const token of TOKENS_ARR ) {
178
+ const { key } = token ;
177
179
const alreadySupported = supported [ key ] ;
178
180
if ( ! alreadySupported ) {
179
181
const isSupported = await this . isSupportedDestToken (
You can’t perform that action at this time.
0 commit comments