Uncaught (in promise) Error: call revert exception [ See: https://links.ethers.org/v5-errors-CALL_EXCEPTION ] (method="name()", data="0x", errorArgs=null, errorName=null, errorSignature=null, reason=null, code=CALL_EXCEPTION, version=abi/5.7.0)
const provider = new ethers.providers.Web3Provider(window.ethereum);
const address = '0x6B175474E89094C44Da98b954EedeAC495271d0F'
const abi = [
"function name() view returns (string)",
"function symbol() view returns (string)",
"function totalSupply() view returns (uint256)"
]
const connectWallet = (async()=>{
await provider.send("eth_requestAccounts",[]);
})
const contract = new ethers.Contract(address,abi,provider);
const getInfo = (async()=>{
const n = await contract.name();
console.log(n)
})
I am trying to read the contract but why I am getting this error ? and how can i solve it??