In the Pot contract, executing the closePot function when not all players (i_players) have claimed their rewards results in a scenario where the remaining tokens become stuck in the contract and cannot be retrieved by the last players claim.
Pot::closePot calculated claimantCut with (remainingRewards - managerCut) / i_players.length and then do the distribution with for (uint256 i = 0; i < claimants.length; i++) but claimants.length != i_players.length
After Pot::closePot It is possible to run Pot::claimCut but the last user wil be not get any reward, then their tokens are stucked in the contract, for ever!
add following test in TestMyCut.t.sol:
Chage Pot::closePot claimantCut calculation i_players.length for claimants.length
Manual Review
Foundry test
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.