Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion src/ATokenVault.sol
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,7 @@ contract ATokenVault is ERC4626Upgradeable, OwnableUpgradeable, EIP712Upgradeabl
}

/// @inheritdoc IATokenVault
function claimRewards(address to) public override onlyOwner {
function claimRewards(address to) public override onlyOwner returns (address[] memory, uint256[] memory) {
require(to != address(0), "CANNOT_CLAIM_TO_ZERO_ADDRESS");

address[] memory assets = new address[](1);
Expand All @@ -441,6 +441,8 @@ contract ATokenVault is ERC4626Upgradeable, OwnableUpgradeable, EIP712Upgradeabl
).claimAllRewards(assets, to);

emit RewardsClaimed(to, rewardsList, claimedAmounts);

return (rewardsList, claimedAmounts);
}

/// @inheritdoc IATokenVault
Expand Down
4 changes: 3 additions & 1 deletion src/interfaces/IATokenVault.sol
Original file line number Diff line number Diff line change
Expand Up @@ -394,8 +394,10 @@ interface IATokenVault is IERC4626Upgradeable {
* @notice Claims any additional Aave rewards earned from vault deposits.
* @dev Only callable by the owner
* @param to The address to receive any rewards tokens
* @return The list of addresses of the rewards that have been claimed
* @return The list of amounts of rewards that have been claimed
*/
function claimRewards(address to) external;
function claimRewards(address to) external returns (address[] memory, uint256[] memory);

/**
* @notice Rescue any tokens other than the vault's aToken which may have accidentally been transferred to this
Expand Down
Loading