Don't fetch token transaction history for accounts with many holdings (#12304)

This commit is contained in:
Justin Starry
2020-09-17 11:27:56 +08:00
committed by GitHub
parent 123e2a1cc1
commit 8d6af087a2

View File

@ -37,6 +37,12 @@ export function TokenHistoryCard({ pubkey }: { pubkey: PublicKey }) {
const tokens = ownedTokens.data?.tokens;
if (tokens === undefined || tokens.length === 0) return null;
if (tokens.length > 25) {
return (
<ErrorCard text="Token transaction history is not available for accounts with over 25 token accounts" />
);
}
return <TokenHistoryTable tokens={tokens} />;
}