InfraredV1_5

Git Source

Inherits: InfraredV1_4, IInfraredV1_5

Upgrade adds claiming BGT on behalf of external user using berachain reward vaults directly, minting iBGT to user.

Implements IInfrared_V1_5, inheriting from InfraredV1_4. Maintains UUPS upgradeability. Uses updated RewardLib to allow external validator boosting via existing functions.

Functions

claimExternalVaultRewards

Claims all the BGT rewards for the user associated with the berachain vault given staking token.

function claimExternalVaultRewards(address _asset, address user)
    external
    whenNotPaused;

Parameters

NameTypeDescription
_assetaddressaddress The address of the staking asset that the vault is for.
useraddressaddress The address of the user to get rewards for and mint ibgt to

externalVaultRewards

View expected iBGT rewards to claim for the user associated with the berachain vault given staking token.

function externalVaultRewards(address _asset, address user)
    external
    view
    returns (uint256 iBgtAmount);

Parameters

NameTypeDescription
_assetaddressaddress The address of the staking asset that the vault is for.
useraddressaddress The address of the user to get rewards for and mint ibgt to

Returns

NameTypeDescription
iBgtAmountuint256amount of iBGT to be minted to user