Protocol Extensions
Last updated
Was this helpful?
Moolah extends Morpho Blue with protocol-level controls designed for production risk management and product flexibility.
minLoan)Each market can enforce a minimum borrow amount.
Borrow transactions that result in debt below minLoan revert.
Partial repay transactions that leave remaining debt below minLoan also revert.
This avoids dust positions that are expensive to liquidate and can increase bad-debt risk.
State-changing paths apply nonReentrant guards, including:
supply()
borrow()
repay()
withdrawCollateral()
liquidate()
Moolah is deployed as an upgradeable system.
Upgrade authority is controlled by DEFAULT_ADMIN_ROLE.
Execution is delayed by TimeLock.
TimeLock provides a 1-day review window before upgrade takes effect.
Moolah oracles expose a peek() interface with 8-decimal price scale (1e8).
For resilient/multi-source oracle design, see:
PT tokens use a linear discount model against underlying asset price before maturity.
Typical use case: PT-based collateral markets such as PT-USDe / USD1
Discount formula:
At maturity, discount goes to zero and oracle returns full underlying price.
Last updated
Was this helpful?
Was this helpful?
discount = baseDiscount x (timeToMaturity / totalDuration)