Skip to content
This repository has been archived by the owner on Jun 24, 2022. It is now read-only.

Re-enable Gnsosis Safe for xDAI #2004

Merged
merged 3 commits into from
Dec 16, 2021
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 1 addition & 8 deletions src/custom/hooks/useWalletInfo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import { getProviderType, WalletProvider } from 'connectors'
import { useActiveWeb3Instance } from 'hooks/index'
import { getSafeInfo } from 'api/gnosisSafe'
import { SafeInfoResponse } from '@gnosis.pm/safe-service-client'
import { ChainId } from '../state/lists/actions'

const GNOSIS_SAFE_WALLET_NAMES = ['Gnosis Safe Multisig', 'Gnosis Safe']

Expand Down Expand Up @@ -46,19 +45,13 @@ function checkIsSupportedWallet(params: {
chainId?: number
gnosisSafeInfo?: SafeInfoResponse
}): boolean {
const { walletName, chainId, gnosisSafeInfo } = params
const { walletName } = params

if (walletName && UNSUPPORTED_WC_WALLETS.has(walletName)) {
// Unsupported wallet
return false
}

if (chainId === ChainId.XDAI && !!gnosisSafeInfo) {
// Gnosis Safe is unsupported in xDAI
// See https://github.com/gnosis/safe-react/issues/2999 and https://github.com/gnosis/safe-react/issues/3002
return false
}

return true
}

Expand Down