The value of individual _share can be 0 even after staking non zero amount of tokens
uint256 _share = _supplied * _delta / 1e18;
Here it calculate the individaual share through supplied amount
1. Let say first deposited 100 tokens first, which will update only supplyIndex[recipient] = index;
for the user since balance is updated after updateFor(msg.sender) call and for the protocol it
will update index and balance.
2. Second time i deposit the 150 token, it will update supplyIndex[recipient] = index; and
claimable[recipient] += _share; here supplied amount will be 100 token supply 250 so if we take the index as 1.5
100*index / 250
the share value will be yield as zero
User can lose its reward
manual review
Add the check - require(_share != 0,"err_msg");
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.