Skip to content

FluidMerkleDistributorCore ​

validAddress ​

solidity
modifier validAddress(address value_)

validates that an address is not the zero address

FluidMerkleDistributorAdmin ​

updateProposer ​

solidity
function updateProposer(address proposer_, bool isProposer_) public

Updates an address status as a root proposer

Parameters ​

NameTypeDescription
proposer_addressThe address to update
isProposer_boolWhether or not the address should be an allowed proposer

updateApprover ​

solidity
function updateApprover(address approver_, bool isApprover_) public

Updates an address status as a root approver

Parameters ​

NameTypeDescription
approver_addressThe address to update
isApprover_boolWhether or not the address should be an allowed approver

spell ​

solidity
function spell(address[] targets_, bytes[] calldatas_) public

open payload method for admin to resolve emergency cases

pause ​

solidity
function pause() external

Pause contract functionality of new roots and claiming

unpause ​

solidity
function unpause() external

Unpause contract functionality of new roots and claiming

FluidMerkleDistributorApprover ​

onlyApprover ​

solidity
modifier onlyApprover()

Checks that the sender is an approver

isApprover ​

solidity
function isApprover(address approver_) public view returns (bool)

checks if the approver_ is an allowed root approver

approveRoot ​

solidity
function approveRoot(bytes32 root_, bytes32 contentHash_, uint40 cycle_, uint40 startBlock_, uint40 endBlock_) external

Approve the current pending root and content hash

FluidMerkleDistributorProposer ​

onlyProposer ​

solidity
modifier onlyProposer()

Checks that the sender is a proposer

isProposer ​

solidity
function isProposer(address proposer_) public view returns (bool)

checks if the proposer_ is an allowed root proposer

proposeRoot ​

solidity
function proposeRoot(bytes32 root_, bytes32 contentHash_, uint40 cycle_, uint40 startBlock_, uint40 endBlock_) external

Propose a new root and content hash, which will be stored as pending until approved

FluidMerkleDistributor ​

constructor ​

solidity
constructor(address owner_, address proposer_, address approver_, address rewardToken_) public

hasPendingRoot ​

solidity
function hasPendingRoot() external view returns (bool)

checks if there is a proposed root waiting to be approved

currentMerkleCycle ​

solidity
function currentMerkleCycle() public view returns (struct Structs.MerkleCycle)

merkle root data related to current cycle (proposed and approved).

pendingMerkleCycle ​

solidity
function pendingMerkleCycle() public view returns (struct Structs.MerkleCycle)

merkle root data related to pending cycle (proposed but not yet approved).

encodeClaim ​

solidity
function encodeClaim(address recipient_, uint256 cumulativeAmount_, bytes32 positionId_, uint256 cycle_) public pure returns (bytes encoded_, bytes32 hash_)

claim ​

solidity
function claim(address recipient_, uint256 cumulativeAmount_, bytes32 positionId_, uint256 cycle_, bytes32[] merkleProof_) external