From bccff55abe7b1ae8b504cedc0e06ae08b73ed031 Mon Sep 17 00:00:00 2001 From: Matthias Kretschmann Date: Fri, 31 Jul 2020 11:31:13 +0200 Subject: [PATCH] =?UTF-8?q?networkChanged=20=E2=86=92=20chainChanged?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/providers/OceanProvider/OceanProvider.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/providers/OceanProvider/OceanProvider.tsx b/src/providers/OceanProvider/OceanProvider.tsx index 0359054..2ce84e8 100644 --- a/src/providers/OceanProvider/OceanProvider.tsx +++ b/src/providers/OceanProvider/OceanProvider.tsx @@ -143,7 +143,7 @@ function OceanProvider({ const handleNetworkChanged = async (networkId: string | number) => { Logger.debug( - "Handling 'networkChanged' event with payload", + "Handling 'chainChanged' event with payload", networkId, status ) @@ -157,11 +157,11 @@ function OceanProvider({ if (web3Provider !== undefined && web3Provider !== null) { web3Provider.on('accountsChanged', handleAccountsChanged) - web3Provider.on('networkChanged', handleNetworkChanged) + web3Provider.on('chainChanged', handleNetworkChanged) return () => { web3Provider.removeListener('accountsChanged', handleAccountsChanged) - web3Provider.removeListener('networkChanged', handleNetworkChanged) + web3Provider.removeListener('chainChanged', handleNetworkChanged) } } }, [web3Modal, web3Provider])