The notHalted modifier in depositMultiple() is redundant because it is checked (multiple times) by the underlying function call to deposit().
Further optimizations may be done to implement an internal _deposit() function that will be called by both deposit() and depositMultiple() so that notHalted is only checked once.
Recommended Mitigation Steps
Remove the notHalted modifier in depositMultiple().
Handle
hickuphh3
Vulnerability details
Impact
The
notHalted
modifier indepositMultiple()
is redundant because it is checked (multiple times) by the underlying function call todeposit()
.Further optimizations may be done to implement an internal
_deposit()
function that will be called by bothdeposit()
anddepositMultiple()
so thatnotHalted
is only checked once.Recommended Mitigation Steps
Remove the
notHalted
modifier indepositMultiple()
.