Skip to content

fix(TokenUtils): Handle testnet chainId being passed into getL1TokenInfo #1002

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Apr 30, 2025

Conversation

nicholaspai
Copy link
Member

No description provided.

@@ -138,10 +138,10 @@ export function getUsdcSymbol(l2Token: string, chainId: number): string | undefi
}

export function getL1TokenInfo(l2TokenAddress: string, chainId: number): L1Token {
if (chainId === CHAIN_IDs.MAINNET)
if ((chainIsProd(chainId) && chainId === CHAIN_IDs.MAINNET) || chainId === CHAIN_IDs.SEPOLIA)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you just need to do if(chainIsL1(chainId)) here.

@nicholaspai nicholaspai requested a review from bmzig April 30, 2025 02:56
@nicholaspai nicholaspai merged commit 3ef0608 into master Apr 30, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants