Description:
Stakers who accidentally/unintentionally withdraw some/all of their tokens from the staking contract without first claiming their rewards will lose some/all of their staking rewards.
Proof of Concept:
Add test to StakingTest.t.sol
Tools Used:
Manual Review
Recommendation:
Staking::claimRewards
should be called on withdraw if the staker has any rewards i.e lastClaim
> 1 week
If we we implement a correct claimRewards function with its intended logic, this would indeed be an issue. I believe low severity for this findings and its duplicates to be appropriate given it is dependent on users lack of understanding of claiming rewards first before a withdrawal.
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.