if you calculate the exclusion fee only once and store it in a variable, gas costs will be reduced:
mapEra_Emission[1] / 16
event better, as mapEra_Emission[1] is set initially in the constructor, this fee amount could also be calculated in the constructor and stored in a constant variable as it never changes. even comment says "Pay fee of 128 Vether". Same here:
uint maxEmissions = (upgradeHeight - 1) * mapEra_Emission[1];
Handle
paulius.eth
Vulnerability details
Impact
if you calculate the exclusion fee only once and store it in a variable, gas costs will be reduced: mapEra_Emission[1] / 16 event better, as mapEra_Emission[1] is set initially in the constructor, this fee amount could also be calculated in the constructor and stored in a constant variable as it never changes. even comment says "Pay fee of 128 Vether". Same here: uint maxEmissions = (upgradeHeight - 1) * mapEra_Emission[1];