Submitted by cmichel, also found by pedroais
NFTVault.sol#L212
The setDebtInterestApr changes the debt interest rate without first accruing the debt.
This means that the new debt interest rate is applied retroactively to the unaccrued period on next accrue() call.
It should never be applied retroactively to a previous time window as this is unfair & wrong.
Borrowers can incur more debt than they should.
Call accrue() first in setDebtInterestApr before setting the new settings.debtInterestApr.
spaghettieth (JPEGd) confirmed
spaghettieth (JPEGd) resolved and commented:
