Gas Optimizations #5
Labels
bug
Something isn't working
G (Gas Optimization)
resolved
Finding has been patched by sponsor (sponsor pls link to PR containing fix)
sponsor confirmed
Sponsor agrees this is a problem and intends to fix it (OK to use w/ "disagree with severity")
https://github.com/code-423n4/2022-05-backd/blob/main/protocol/contracts/utils/Preparable.sol#L143
Function _setConfig: No need to set deadlines[key] = 0; as this was already done in _executeDeadline function
https://github.com/code-423n4/2022-05-backd/blob/main/protocol/contracts/tokenomics/Minter.sol#L218
Function _mint: Check that amount is not equal to zero
Note: do same for mintNonInflationTokens
https://github.com/code-423n4/2022-05-backd/blob/main/protocol/contracts/tokenomics/LpGauge.sol#L59
Function claimRewards: Since amount is uint type so amount cannot be <0. Change it to
Note: Same need to be fixed for other Gauge like AMMGauge
https://github.com/code-423n4/2022-05-backd/blob/main/protocol/contracts/BkdLocker.sol#L214
Function claimFees: If claimable is zero, no need to go further
The text was updated successfully, but these errors were encountered: