Skip to content

Commit

Permalink
fix swap (#3275)
Browse files Browse the repository at this point in the history
  • Loading branch information
wow-sven authored Feb 6, 2025
1 parent 17daff7 commit 1b76269
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ export default function SelectTokenPair({ onLoading, onCallback }: SelectTokenPa
setYCount(formatByIntl(fixdYCount.toString()));

const xCoin = assetsMap?.get(x.type)!;
const yCoin = assetsMap?.get(y.type)!;
const yCoin = assetsMap?.get(y.type);
onCallback(
{
balance: xCoin.fixedBalance,
Expand All @@ -166,12 +166,12 @@ export default function SelectTokenPair({ onLoading, onCallback }: SelectTokenPa
decimal: xCoin.decimals,
},
{
balance: yCoin.fixedBalance,
type: yCoin.coin_type,
icon: yCoin.icon_url || undefined,
symbol: yCoin.symbol,
balance: yCoin?.fixedBalance || 0,
type: yCoin?.coin_type || y.type,
icon: yCoin?.icon_url || undefined,
symbol: yCoin?.symbol || y.name,
amount: fixdYCount.toString(),
decimal: yCoin.decimals,
decimal: yCoin?.decimals || 0, // TODO: fix
}
);
} catch (e) {
Expand Down

0 comments on commit 1b76269

Please sign in to comment.