Tracking Netwroks - Avalanche error

maybe MetaMask is connected to ETH network? I tested now few networks and it looks like it works fine.

getChainId() works for all networks besides avalanche. Please kindly take a look at the other users’ messages, too. We all have the same issue. getChainId() returns 1 for avalanche. thank you

Hey @junkseeker

It’s a known buggy behavior of Web3.js which we use in our Moralis library

1 Like

We will notify when we will find a solution for this and add it to the library :raised_hands:

It really depends from which chain are you switching to avalanche

from which chain are you switching?

you can try to use id = await web3.eth.getChainId() for now