20,000 USDC
View results
Submission Details
Severity: gas
Valid

cache the state variable to the stake before the loop

Vulnerability Details

update and read from the storage in the for loop cost much gas

Impact

gas optimization

Tools Used

manual review

Recommendations

caching the loans[loanId] to a stake before the loop will save gas.

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.