Function: withdraw(address token, uint256 amount)

This function withdraws the caller’s available (unlocked) funds of token to themselves after settling lockups.

Inputs

  • token

    • Control: Fully controlled by the caller.

    • Constraints: N/A.

    • Impact: Asset to withdraw from caller’s account.

  • amount

    • Control: Fully controlled by the caller.

    • Constraints: Must be less than or equal to the unlocked balance after settlement.

    • Impact: Amount to withdraw to the caller.

Branches and code coverage

Intended branches

  • Success — withdraw to self (native/ERC-20).

  • Revert — amount > unlocked after settlement.

Zellic © 2025Back to top ↑