mirror of
https://github.com/Instadapp/dsa-resolvers-deprecated.git
synced 2024-07-29 22:38:16 +00:00
Add debt floor
This commit is contained in:
parent
9c6da8bd4d
commit
5ebb99aa8e
|
@ -111,6 +111,7 @@ contract Helpers is DSMath {
|
||||||
uint price;
|
uint price;
|
||||||
uint liquidationRatio;
|
uint liquidationRatio;
|
||||||
uint debtCelling;
|
uint debtCelling;
|
||||||
|
uint debtFloor;
|
||||||
uint totalDebt;
|
uint totalDebt;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -171,6 +172,11 @@ contract Helpers is DSMath {
|
||||||
debtCeiling = debtCeilingRad / 10 ** 45;
|
debtCeiling = debtCeilingRad / 10 ** 45;
|
||||||
totalDebt = rmul(totalArt, rate);
|
totalDebt = rmul(totalArt, rate);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function getDebtFloor(bytes32 ilk) internal view returns(uint debtFloor) {
|
||||||
|
address vat = InstaMcdAddress(getMcdAddresses()).vat();
|
||||||
|
(,,,,debtFloor) = VatLike(vat).ilks(ilk);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -242,6 +248,7 @@ contract VaultResolver is Helpers {
|
||||||
getColPrice(ilk),
|
getColPrice(ilk),
|
||||||
getColRatio(ilk),
|
getColRatio(ilk),
|
||||||
debtCeiling,
|
debtCeiling,
|
||||||
|
getDebtFloor(ilk),
|
||||||
totalDebt
|
totalDebt
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user