Skip to content

Commit

Permalink
fix: do not disable currently selected network in the network selector (
Browse files Browse the repository at this point in the history
  • Loading branch information
jmealy committed Sep 23, 2024
1 parent 2f8d774 commit a4ee3d6
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,9 @@ const NetworkMultiSelector = ({
if (isAdvancedFlow) return optionNetwork.chainId != firstSelectedNetwork.chainId

// Check required feature toggles
const optionIsSelectedNetwork = firstSelectedNetwork.chainId === optionNetwork.chainId
if (!hasMultiChainCreationFeatures(optionNetwork) || !hasMultiChainCreationFeatures(firstSelectedNetwork)) {
return true
return !optionIsSelectedNetwork
}

// Check if required deployments are available
Expand All @@ -88,7 +89,7 @@ const NetworkMultiSelector = ({
)

// Only 1.4.1 safes with canonical deployment addresses can be deployed as part of a multichain group
if (!selectedHasCanonicalSingletonDeployment) return firstSelectedNetwork.chainId !== optionNetwork.chainId
if (!selectedHasCanonicalSingletonDeployment) return !optionIsSelectedNetwork
return !optionHasCanonicalSingletonDeployment
},
[isAdvancedFlow, selectedNetworks],
Expand Down

0 comments on commit a4ee3d6

Please sign in to comment.