Skip to content

Commit

Permalink
Revert "feat: display USDC instead of fUSDC on mainnet (#218)"
Browse files Browse the repository at this point in the history
This reverts commit 97aa4de.
  • Loading branch information
af-afk committed Dec 13, 2024
1 parent 9e6cd05 commit a6f9704
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions web/src/config/tokens.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,10 @@ import { useSwapStore } from "@/stores/useSwapStore";
import { EmptyToken } from "@/lib/utils";
import { useStakeStore } from "@/stores/useStakeStore";
import { useChainId } from "wagmi";
import { allChains, superpositionMainnet, useChain } from "./chains";
import { allChains, useChain } from "./chains";

export type ChainIdTypes = (typeof allChains)[number]["id"];

function getDisplaySymbol(symbol: string, chainId: number): string {
if (chainId === superpositionMainnet.id && symbol.toLowerCase() === "fusdc") {
return "USDC";
}
return symbol;
}

export type Token = {
address: `0x${string}`;
symbol: string;
Expand Down Expand Up @@ -99,7 +92,6 @@ export function useTokens(token?: "default" | string) {
...t.token,
address: t.token.address as `0x${string}`,
icon: t.token.image,
symbol: getDisplaySymbol(t.token.symbol, chainId),
...(isGasToken(t.token.symbol)
? {
abi: WETH10,
Expand All @@ -113,7 +105,7 @@ export function useTokens(token?: "default" | string) {
}),
{} as { [symbol: string]: Token },
);
}, [tokensData, fusdcData_, isGasToken, chainId]);
}, [tokensData, fusdcData_, isGasToken]);
const isTokens = fusdcData_ && tokensData;

const DefaultToken = isTokens
Expand Down

0 comments on commit a6f9704

Please sign in to comment.