Skip to content

Commit

Permalink
Override _totalValueInVault
Browse files Browse the repository at this point in the history
  • Loading branch information
shahthepro committed Jul 15, 2024
1 parent cbd6764 commit ef45537
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions contracts/contracts/vault/OETHVaultCore.sol
Original file line number Diff line number Diff line change
Expand Up @@ -375,8 +375,15 @@ contract OETHVaultCore is VaultCore {
super._allocate();
}

function _totalValue() internal view override returns (uint256 value) {
value = super._totalValue();
function _totalValueInVault()
internal
view
virtual
override
returns (uint256 value)
{
// Only WETH is counted
value = IERC20(weth).balanceOf(address(this));

// Need to remove WETH that is reserved for the withdrawal queue.
// reserved for the withdrawal queue = cumulative queued total - total claimed
Expand Down

0 comments on commit ef45537

Please sign in to comment.