Fixed mcd Save

This commit is contained in:
Thrilok Kumar 2019-12-13 23:07:40 +05:30
parent d65da6bec7
commit 296af8b2dd

View File

@ -282,7 +282,7 @@ contract MakerHelpers is Helpers {
function joinDaiJoin(address urn, uint wad) internal {
address daiJoin = InstaMcdAddress(getMcdAddresses()).daiJoin();
// Gets DAI from the user's wallet
DaiJoinLike(daiJoin).dai().transferFrom(msg.sender, address(this), wad);
// DaiJoinLike(daiJoin).dai().transferFrom(msg.sender, address(this), wad); // getting dai from eth swap.
// Approves adapter to take the DAI amount
DaiJoinLike(daiJoin).dai().approve(daiJoin, wad);
// Joins DAI into the vat
@ -638,7 +638,6 @@ contract Save is GetDetails {
uint maxDebtLimit = sub(wdiv(colToUSD, 1500000000000000000), 10);
debtToBorrow = sub(maxDebtLimit, daiDebt);
}
}