Skip to content

Add additional argument to add_liquidity_stableswap_omnipool_and_join_farms#3296

Open
vkulinich-cl wants to merge 19 commits into
nextfrom
feat/stableswap-extrinsic
Open

Add additional argument to add_liquidity_stableswap_omnipool_and_join_farms#3296
vkulinich-cl wants to merge 19 commits into
nextfrom
feat/stableswap-extrinsic

Conversation

@vkulinich-cl
Copy link
Copy Markdown
Collaborator

@vkulinich-cl vkulinich-cl commented Jan 14, 2026

No description provided.

@netlify
Copy link
Copy Markdown

netlify Bot commented Jan 14, 2026

Deploy Preview for next-hydration failed. Why did it fail? →

Name Link
🔨 Latest commit 35a8884
🔍 Latest deploy log https://app.netlify.com/projects/next-hydration/deploys/6981f6277c10410008857a40

@vkulinich-cl vkulinich-cl requested a review from jvonasek January 20, 2026 09:48
@vkulinich-cl vkulinich-cl marked this pull request as ready for review January 20, 2026 09:49
@vkulinich-cl vkulinich-cl linked an issue Jan 21, 2026 that may be closed by this pull request
const addebleReserves = useAddableStablepoolTokens(stableswapId, reserves)
const { account } = useAccount()
const meta = getAssetWithFallback(stableswapId)
const getOmnipoolGetShares = useLiquidityOmnipoolShares(stableswapId)
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

strange name, 2x "get"

Comment on lines +116 to +118
const position = positionId
? omnipoolPositions.find((position) => position.positionId === positionId)
: undefined
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dont need to check for positionId again

Comment on lines +177 to +181
rangeLow={0.34}
rangeHigh={0.66}
value={Number(fee)}
valueDisplay={feeDisplay}
range={[0.01, 0.34, 0.66, 1]}
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

extract these numbers to separate const, since you are using them in multiple places

const FEE_RANGE = {
  low: 0.34,
  high: 0.66,
  full: [0.01, 0.34, 0.66, 1] as const,
}

mutationFn: async (): Promise<void> => {
if (!receiveAssetsProportionally)
throw new Error("Receive assets not found")
if (!receiveAssets) throw new Error("Receive assets not found")
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

doesnt look like you need this check, since receiveAssets from useMemo is always an array

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Testing of adding/removing liquidity general+new extrinsics

2 participants