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

missed check for the length of two arrays

there is no check for the length of the two array loanIds[] and poolIds[] although the length of them should match .

impact

without checking the length of the arrays loanIds[] and poolIds[] , it will waste much gas to execute the function and the for loop then revert after that .

Recommendation

check if the length of the two arrays loanIds[] and poolIds[] match befor the for loop .
if (loanIds.length != poolIds.length ) revert lengthNotMatches(); will prevent going through the loop without matching lengths .

Support

FAQs

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