Verified contractExactMIT
LiquityClaimProxy
Address0xcc7ad26fdc00730b54e9ee2fa54e726aaec3dc2a
- Balance
0 ETH
- Transactions
1
- Compiler
solc 0.8.24
- Same code
Only this contract
Details
- Compiler
- solc 0.8.24+commit.e11b9ed9
- Language
- solidity
- Optimization
- No
- License
- MIT
- Match
- Exactcreation code: yes, runtime code: yes
- Verified on Sourcify
- Created in block
- 26,333,606
- Creation transaction
- 0xd86be469ae…bfc670c3c9
claim.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.24;
interface ILiquityGovernance {
function claimFromStakingV1(address rewardRecipient)
external
returns (uint256 lusdSent, uint256 ethSent);
}
contract LiquityClaimProxy {
address public immutable governance;
event ClaimExecuted(
address indexed caller,
address indexed rewardRecipient,
uint256 lusdSent,
uint256 ethSent
);
constructor(address _governance) {
require(_governance != address(0), "Zero address");
require(_governance.code.length > 0, "Not a contract");
governance = _governance;
}
/// @notice Calls Liquity's V1 staking reward claim.
/// @dev The caller is this proxy, not the reward recipient.
function claimFromStaking(address rewardRecipient)
external
returns (uint256 lusdSent, uint256 ethSent)
{
require(rewardRecipient != address(0), "Zero recipient");
(lusdSent, ethSent) =
ILiquityGovernance(governance)
.claimFromStakingV1(rewardRecipient);
emit ClaimExecuted(
msg.sender,
rewardRecipient,
lusdSent,
ethSent
);
}
/// @notice Batch claims for multiple reward recipients.
function claimMany(address[] calldata recipients)
external
{
require(recipients.length > 0, "Empty list");
require(recipients.length <= 50, "Too many recipients");
for (uint256 i = 0; i < recipients.length; i++) {
require(recipients[i] != address(0), "Zero recipient");
(uint256 lusdSent, uint256 ethSent) =
ILiquityGovernance(governance)
.claimFromStakingV1(recipients[i]);
emit ClaimExecuted(
msg.sender,
recipients[i],
lusdSent,
ethSent
);
}
}
}
Compiler settingsShow
{
"optimizer": {
"runs": 200,
"enabled": false
},
"remappings": []
}Source code and metadata: Sourcify.
The source code belongs to the authors of the contract.