

Reads onchain state
Reads how much more an account can borrow on Moonwell, or how far short it has fallen. The comptroller values every market the account has entered at the oracle price and its collateral factor against the sum of its borrows. A healthy account reports its remaining borrowing power as liquidity in USD at 18 decimals with no shortfall; an account past the line reports zero liquidity and the shortfall that makes it liquidatable. Reach for it to repay or add collateral before liquidity runs out, holding liquidity above a floor with a predicate.
Plug lets you combine onchain actions like this one into a single transaction, without writing a smart contract. Use in App opens a new plug with this action already in it.
More on Moonwell · 17