External call can be done later to save gas #236
Labels
bug
Something isn't working
G (Gas Optimization)
sponsor confirmed
Sponsor agrees this is a problem and intends to fix it (OK to use w/ "disagree with severity")
Handle
WatchPug
Vulnerability details
https://github.com/code-423n4/2021-11-bootfinance/blob/f102ee73eb320532c5a7c1e833f225c479577e39/customswap/contracts/SwapUtils.sol#L1362-L1375
The external call to get the
totalSupply
of thelpToken
can be done later to avoid unnecessary code execution when the check oftokenAmount
andtokenIndex
does not pass.The text was updated successfully, but these errors were encountered: