feat(earn): require NFT permit/approve for univ3 on pancake zap widget - #3307
Merged
Conversation
Extend the NFT authorization step to univ3 (PancakeSwapV3) increase liquidity and add an off-chain permit path (usePermitNft) next to the on-chain approve, matching the main liquidity widget. Gating keys off positionId instead of the pancake-infinity-only check; the approval step shows Permit NFT + Approve NFT side by side. Permit stays dormant until the backend returns routerPermitAddress for pancake pools.
Auto Deploy Pull RequestADPR instance has been created! Information
|
Only apply the new NFT permit/approve requirement for univ3 positions on ZapRouter v3. On v2 (0x0e97C887b61cCd952a53578B04763E7134429e05) keep the legacy flow: univ3 zaps straight through and only Pancake Infinity CL positions need an on-chain NFT approve (no permit). Gating keys off requiresNftAuth = positionId && (!isZapV2 || isPancakeInfinityCL).
Auto Deploy Pull RequestNotes:
|
viet-nv
reviewed
Aug 3, 2026
Use zapInfo.routerAddress as the permit spender instead of the optional routerPermitAddress the pancake route response doesn't provide, so the permit path activates on v3 (the router that pulls the NFT is the same contract that verifies the permit).
Auto Deploy Pull RequestNotes:
|
Auto Deploy Pull RequestNotes:
|
viet-nv
approved these changes
Aug 3, 2026
Auto Deploy Pull RequestClean up resources have been completed! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Extend the NFT authorization step to univ3 (PancakeSwapV3) increase liquidity and add an off-chain permit path (usePermitNft) next to the on-chain approve, matching the main liquidity widget. Gating keys off positionId instead of the pancake-infinity-only check; the approval step shows Permit NFT + Approve NFT side by side. Permit stays dormant until the backend returns routerPermitAddress for pancake pools.