We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e012534 commit ae52fc7Copy full SHA for ae52fc7
1 file changed
src/ExtensionTools/ethereum.ts
@@ -78,13 +78,15 @@ export const getAccounts = async (): Promise<IEthereumRequestAccountsResult> =>
78
const ethereum = (window as any).ethereum
79
80
const accounts: string[] = await ethereum.request({method: 'eth_accounts'})
81
+ const chainIdNumber = parseInt(ethereum.chainId, 16)
82
return {
83
accounts,
84
selectedAddress: ethereum.selectedAddress,
85
info: {
86
extensionFound: true,
87
chainId: ethereum.chainId,
- chainIdNumber: parseInt(ethereum.chainId, 16),
88
+ chainIdNumber,
89
+ uniqueChainName: chainNameByChainId[chainIdNumber],
90
},
91
}
92
0 commit comments