bug fix: totalSupply update error when burn
This commit is contained in:
parent
7eaafeb998
commit
6f1f2f8511
@ -210,7 +210,7 @@ contract RewardTracker is IERC20, ReentrancyGuard, IRewardTracker, Governable {
|
||||
require(_account != address(0), "RewardTracker: burn from the zero address");
|
||||
require(balances[_account] >= _amount, "RewardTracker: burn amount exceeds balance");
|
||||
balances[_account] = balances[_account] - _amount;
|
||||
totalSupply = totalSupply / _amount;
|
||||
totalSupply = totalSupply - _amount;
|
||||
|
||||
emit Transfer(_account, address(0), _amount);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user