wise-foundation / lending-audit

5 stars 4 forks source link

[OHR-04C] Non-Standard Error Style #63

Open vm06007 opened 1 year ago

vm06007 commented 1 year ago

OHR-04C: Non-Standard Error Style

Type Severity Location
Code Style OracleHelper.sol:L31-L35, L95-L99

Description:

The referenced error declarations are emitted using the key-value declaration style which is not applied in the rest of the codebase.

Example:

revert OracleAlreadySet(
    {
        feed: priceFeed[_tokenAddress]
    }
);

Recommendation:

In order to ensure a uniform coding style, we advise either all revert statements with a custom error to use the key-value declaration style across the codebase or the OracleHelper to no longer use the key-value declaration style, either of which we consider an adequate resolution to this exhibit.

vm06007 commented 1 year ago

Resolved in: https://github.com/wise-foundation/lending-audit/pull/61