Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/agent-sdk/src/evm/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ export async function validateRequest<
return null;
}

async function getAdapterAddress(
export async function getAdapterAddress(
accountId: string,
safeSaltNonce: string,
): Promise<Address> {
Expand Down
6 changes: 3 additions & 3 deletions packages/agent-sdk/src/evm/tokens.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,15 @@ export async function getTokenDetails(
symbolOrAddress: string,
tokenMap?: BlockchainMapping,
): Promise<TokenInfo> {
if (isAddress(symbolOrAddress, { strict: false })) {
return getTokenInfo(chainId, symbolOrAddress);
}
if (!tokenMap) {
console.log(
"Loading TokenMap... this should be stored in memory consider setting it with loadTokenMap() in your app and passing it here.",
);
tokenMap = await loadTokenMap();
}
if (isAddress(symbolOrAddress, { strict: false })) {
return getTokenInfo(chainId, symbolOrAddress);
}
console.log("Seeking TokenMap for Symbol", symbolOrAddress);
// TokenMap has lower cased (sanitized) symbols
return tokenMap[chainId][symbolOrAddress.toLowerCase()];
Expand Down
Loading