Remove useless bool check for balance adjustment result (they revert instead)

This commit is contained in:
nolash 2021-02-05 13:00:14 +01:00
parent 01155f6e64
commit 26abe066b6
Signed by: lash
GPG Key ID: 21D2E7BB88C2A746
1 changed files with 3 additions and 6 deletions

View File

@ -317,12 +317,9 @@ contract RedistributedDemurrageToken {
function transferBase(address _from, address _to, uint256 _value) private returns (bool) {
uint256 period;
if (!decreaseBaseBalance(_from, _value)) {
revert('ERR_TX_DECREASEBALANCE');
}
if (!increaseBaseBalance(_to, _value)) {
revert('ERR_TX_INCREASEBALANCE');
}
decreaseBaseBalance(_from, _value);
increaseBaseBalance(_to, _value);
period = actualPeriod();
if (_value > 0 && accountPeriod(_from) != period) {
registerAccountPeriod(_from, period);