Blade Pool LP withdraw process

unlockDeposit() → returns (uint256 poolTokens)

Unlocks LP tokens after the vesting period ends.

Process Overview:

  • Verify if the caller has a vested deposit.

  • Ensure the lock period has ended.

  • Transfer the LP tokens to the caller.

  • Remove the vesting record.

Does not withdraw assets. Only gives access to LP tokens. LP tokens must have been created using a vesting deposit.

burnToWithdraw(uint256 amount)

Burns the caller’s LP tokens and withdraws their proportional share of all pool assets.

Process Overview:

  • Calculates the fraction of the pool being burned.

  • Burns LP tokens from the caller.

  • Transfers a proportional amount of each asset in the pool.

  • Emits a Withdrawn event.

No vesting needed. Useful for instant withdrawals. Only works if the caller already holds LP tokens.

Last updated

Was this helpful?