Skip to content

Commit

Permalink
fix: remove vaultConnected condition from useIsOffchainAaveWithdrawSu…
Browse files Browse the repository at this point in the history
…pported
  • Loading branch information
D-Ig committed Jan 28, 2025
1 parent b73303e commit 9587c07
Showing 1 changed file with 1 addition and 5 deletions.
Original file line number Diff line number Diff line change
@@ -1,13 +1,9 @@
import { useTradingPanelPoolConfig } from 'core-kit/hooks/state'
import { useIsDhedgeVaultConnected } from 'core-kit/hooks/user'
import { useConfigContextParams } from 'trading-widget/providers/config-provider'

export const useIsOffchainAaveWithdrawSupported = () => {
const { chainId } = useTradingPanelPoolConfig()
const { aaveOffchainWithdrawChainIds } = useConfigContextParams()
const isDhedgeVaultConnected = useIsDhedgeVaultConnected()

return (
aaveOffchainWithdrawChainIds.includes(chainId) && !isDhedgeVaultConnected
)
return aaveOffchainWithdrawChainIds.includes(chainId)
}

0 comments on commit 9587c07

Please sign in to comment.