Skip to content

Commit fa93fa3

Browse files
cursoragentshane
andcommitted
Fix: Exclude Arbitrum chains from token holders endpoint
Co-authored-by: shane <[email protected]>
1 parent 2863e7d commit fa93fa3

File tree

2 files changed

+12
-1
lines changed

2 files changed

+12
-1
lines changed

snippets/supported-chains-accordion.mdx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,8 @@ export const SupportedChainsAccordion = () => {
3939
if (chain.collectibles && chain.collectibles.supported) collectiblesCount++;
4040
if (chain.transactions && chain.transactions.supported) transactionsCount++;
4141
if (chain.token_info && chain.token_info.supported) tokenInfoCount++;
42-
if (chain.token_holders && chain.token_holders.supported) tokenHoldersCount++;
42+
// Exclude Arbitrum chains (42161, 42170) from Token Holders count as they're not actually supported
43+
if (chain.token_holders && chain.token_holders.supported && chain.chain_id !== 42161 && chain.chain_id !== 42170) tokenHoldersCount++;
4344
}
4445

4546
setCounts({
@@ -94,6 +95,11 @@ export const SupportedChainsAccordion = () => {
9495
for (var i = 0; i < data.chains.length; i++) {
9596
var chain = data.chains[i];
9697
if (chain[endpoint] && chain[endpoint].supported) {
98+
// Temporary filter: Remove Arbitrum chains from Token Holders API
99+
// These chains are not actually supported despite what the API returns
100+
if (endpoint === "token_holders" && (chain.chain_id === 42161 || chain.chain_id === 42170)) {
101+
continue;
102+
}
97103
supportedChains.push(chain);
98104
}
99105
}

snippets/supported-chains.mdx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,11 @@ export const SupportedChains = ({ endpoint, title }) => {
3535
for (var i = 0; i < data.chains.length; i++) {
3636
var chain = data.chains[i];
3737
if (chain[endpoint] && chain[endpoint].supported) {
38+
// Temporary filter: Remove Arbitrum chains from Token Holders API
39+
// These chains are not actually supported despite what the API returns
40+
if (endpoint === 'token_holders' && (chain.chain_id === 42161 || chain.chain_id === 42170)) {
41+
continue;
42+
}
3843
supportedChains.push(chain);
3944
}
4045
}

0 commit comments

Comments
 (0)