Skip to content

Commit

Permalink
fix: set sbtc marketcap rank to n/a
Browse files Browse the repository at this point in the history
  • Loading branch information
BLuEScioN committed Dec 20, 2024
1 parent dd15c0c commit 8be69dd
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/app/token/[tokenId]/TokenInfo/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ export const TokenInfo: FC<{ tokenInfo: TokenInfoProps; tokenId: string }> = ({
const isSBTC = getIsSBTC(tokenId);
const sBTCMarketCapOverride = // LunarCrush is returning an incorrect circulating supply for SBTC, resulting in an incorrect market cap. Manually overriding it here.
circulatingSupply && currentPrice ? circulatingSupply * currentPrice : undefined;
const sbtcMarketCapRank = null;
return (
<ErrorBoundary fallbackRender={() => null}>
<Wrapper>
Expand All @@ -41,7 +42,10 @@ export const TokenInfo: FC<{ tokenInfo: TokenInfoProps; tokenId: string }> = ({
borderRightWidth={['0px', '0px', '1px', '1px']}
marketCapOverride={isSBTC ? sBTCMarketCapOverride : undefined}
/>
<Transaction txId={tokenId} marketCapRank={tokenInfo.extended?.marketCapRank} />
<Transaction
txId={tokenId}
marketCapRank={isSBTC ? sbtcMarketCapRank : tokenInfo.extended?.marketCapRank}
/>
</Wrapper>
</ErrorBoundary>
);
Expand Down

0 comments on commit 8be69dd

Please sign in to comment.