Skip to content
This repository has been archived by the owner on Jul 3, 2022. It is now read-only.

Commit

Permalink
fix: resolve to not be async when it is not needed (#419)
Browse files Browse the repository at this point in the history
  • Loading branch information
ZhengYuTay authored Jul 2, 2021
1 parent 8cb0309 commit b13bb3f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/lib/tokenlist.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export class GitHubTokenListResolutionStrategy {
'https://raw.githubusercontent.com/solana-labs/token-list/main/src/tokens/solana.tokenlist.json',
];

resolve = async () => {
resolve = () => {
return queryJsonFiles(this.repositories);
};
}
Expand All @@ -74,7 +74,7 @@ export class CDNTokenListResolutionStrategy {
'https://cdn.jsdelivr.net/gh/solana-labs/token-list@main/src/tokens/solana.tokenlist.json',
];

resolve = async () => {
resolve = () => {
return queryJsonFiles(this.repositories);
};
}
Expand Down Expand Up @@ -108,13 +108,13 @@ export enum Strategy {
}

export class SolanaTokenListResolutionStrategy {
resolve = async () => {
resolve = () => {
throw new Error(`Not Implemented Yet.`);
};
}

export class StaticTokenListResolutionStrategy {
resolve = async () => {
resolve = () => {
return tokenlist.tokens;
};
}
Expand Down

0 comments on commit b13bb3f

Please sign in to comment.