Skip to content

Conversation

@grkamil
Copy link
Contributor

@grkamil grkamil commented Mar 18, 2025

No description provided.

@olexandr13 olexandr13 closed this Mar 18, 2025
@olexandr13 olexandr13 reopened this Mar 18, 2025
address[] calldata legacyWithdrawalAddresses,
uint256[] calldata legacyWithdrawalAmounts,
uint256 legacyClaimedAmount
) internal initializer {

Choose a reason for hiding this comment

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

it's internal, why the 'initializer'?


if (targetCapacity == 0) revert InceptionOnPause();
if (receiver == address(0)) revert InvalidAddress();
if (targetCapacity == 0) revert NullParams();
Copy link
Contributor

Choose a reason for hiding this comment

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

I think the error name for (targetCapacity == 0) should be different than (iShares == 0)

whenNotPaused
nonReentrant
{
function withdraw(
Copy link
Contributor

Choose a reason for hiding this comment

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

withdraw implies that a certain amount of assets are to be withdrawn. However, the parameter here is in shares. I believe the name of this method should be changed to something like requestRedeem (Like in ERC7540 Async vault) to avoid confusing it with ERC4626 withdraw assets and synchronous 4626 redeem.

Copy link
Contributor

Choose a reason for hiding this comment

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

Like we requestRedeem and then redeem after being fulfilled.


/** @dev See {IERC4626-previewDeposit}. */
function previewDeposit(uint256 assets) public view returns (uint256) {
if (assets < depositMinAmount) revert LowerMinAmount(depositMinAmount);
Copy link
Contributor

Choose a reason for hiding this comment

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

I think this should be removed since it is vault specific limit.

function previewMint(uint256 shares) public view returns (uint256) {

uint256 assets = Convert.multiplyAndDivideCeil(shares, 1e18, ratio());
if (assets < depositMinAmount) revert LowerMinAmount(depositMinAmount);
Copy link
Contributor

Choose a reason for hiding this comment

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

This should also be removed since this is vault specific limit

* @param claimer Address to check claimable amount for
* @return Amount of claimable tokens for the specified address
*/
function claimableAmount(address claimer) public view virtual returns (uint256) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Didn't fully understand purpose of this function. It is simply returning wstETH (or any asset) balance of a caller ?

* @notice Returns the total amount available for withdrawal
* @return total Amount that can be claimed
*/
function claimableWithdrawalAmount() public view returns (uint256 total) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Was single vault variant claimableWithdrawalAmount(address) removed ?

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants