Commit e36722cc authored by Vignesh Mohankumar's avatar Vignesh Mohankumar Committed by GitHub

refactor: remove coinbase wallet resetState (#4024)

* refactor: remove coinbase wallet resetState

* unused import

* bump web3-react

* rm unused

* bump everything
parent ec0b94a9
import { Trans } from '@lingui/macro'
import { useWeb3React } from '@web3-react/core'
import CopyHelper from 'components/AccountDetails/Copy'
import { coinbaseWalletConnection, injectedConnection } from 'connection'
import { injectedConnection } from 'connection'
import { getConnection } from 'connection/utils'
import { useCallback, useContext } from 'react'
import { ExternalLink as LinkIcon } from 'react-feather'
......@@ -257,13 +257,6 @@ export default function AccountDetails({
onClick={() => {
if (connector.deactivate) {
connector.deactivate()
// Coinbase Wallet SDK does not emit a disconnect event to the provider,
// which is what web3-react uses to reset state. As a workaround we manually
// reset state.
if (connector === coinbaseWalletConnection.connector) {
connector.resetState()
}
} else {
connector.resetState()
}
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment