Skip to content
This repository was archived by the owner on Oct 15, 2024. It is now read-only.

fix: show pi for add liquidity w/o connected wallet #1126

Merged
merged 1 commit into from
Sep 25, 2024
Merged
Changes from all 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
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ type Params = {

export function useAddLiquidityPriceImpactQuery({ handler, humanAmountsIn, enabled }: Params) {
const { pool, chainId } = usePool()
const { userAddress, isConnected } = useUserAccount()
const { userAddress } = useUserAccount()
const { slippage } = useUserSettings()
const debouncedHumanAmountsIn = useDebounce(humanAmountsIn, defaultDebounceMs)[0]
const { data: blockNumber } = useBlockNumber({ chainId })
Expand All @@ -42,7 +42,7 @@ export function useAddLiquidityPriceImpactQuery({ handler, humanAmountsIn, enabl
return useQuery({
queryKey,
queryFn,
enabled: enabled && isConnected && !areEmptyAmounts(debouncedHumanAmountsIn),
enabled: enabled && !areEmptyAmounts(debouncedHumanAmountsIn),
gcTime: 0,
meta: sentryMetaForAddLiquidityHandler('Error in add liquidity priceImpact query', {
...params,
Expand Down
Loading