Skip to content
Request an audit

‹ All findings

In MapleLoanFactory, isLoan has the same functionality of isInstance and thus can be removed.

Low/InfoMaple Finance·Three Sigma · Institutional lending · 10th April, 20243S-MAPLE-N05

Description

The mapping isLoan is only modified in the respective MapleLoanFactory.sol contract which extends MapleProxyFactory.sol. isLoan is only modified in line 24 of MapleLoanFactory where, in the same call, isInstance is also set to true in line 95 of MapleProxyFactory.

So every valid loan according to isLoan is a valid instance according to isInstance and every address that is not registered in isLoan will also not be registered in isInstance.

Recommendation

The mapping isLoan can be removed and isInstance can be used in its place whenever needed.

Status

Acknowledged, this was done to maintain compatibility with the fixed term loan factory (which is out of scope for our audit).