Skip to content

Commit

Permalink
fix: clamped claim
Browse files Browse the repository at this point in the history
  • Loading branch information
GalloDaSballo committed Nov 2, 2024
1 parent d762007 commit 1219a02
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions test/recon/targets/BribeInitiativeTargets.sol
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,19 @@ abstract contract BribeInitiativeTargets is Test, BaseTargetFunctions, Propertie
t(!hasClaimedBribes, "has claimed");
}

function clamped_claimBribes(uint8 initiativeIndex) public {
IBribeInitiative initiative = IBribeInitiative(_getDeployedInitiative(initiativeIndex));

uint16 userEpoch = initiative.getMostRecentUserEpoch(user);
uint16 stateEpoch = initiative.getMostRecentTotalEpoch();
initiative_claimBribes(
governance.epoch() - 1,
userEpoch,
stateEpoch,
initiativeIndex
);
}

function initiative_claimBribes(
uint16 epoch,
uint16 prevAllocationEpoch,
Expand Down

0 comments on commit 1219a02

Please sign in to comment.