From 9e5fe4213e32c29e84b21b194c919bcc1b53e577 Mon Sep 17 00:00:00 2001 From: Christian Henriksen Date: Sun, 16 Jul 2023 21:42:03 +0200 Subject: [PATCH] Fix outcommented code and comment --- src/stores.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/stores.js b/src/stores.js index e7e9cb5..6a4ce3c 100644 --- a/src/stores.js +++ b/src/stores.js @@ -39,9 +39,8 @@ const getWindowEthereum = () => { } } -// always get chainId as number EDIT: Always as hex +// always get chainId as hex (required since web3js 4.x.x) const alwaysHex = (n) => (Web3.utils.isHex(n) ? n : Web3.utils.toHex(n)) -// const alwaysHex = (n) => (Web3.utils.isHex(n) ? Web3.utils.hexToNumber(n) : n) export const createStore = () => { const { emit, get, subscribe, assign, deleteAll } = proxied()