mirror of
https://github.com/Instadapp/smart-contract.git
synced 2024-07-29 22:08:07 +00:00
bug resolved
This commit is contained in:
parent
b21a398a2c
commit
c964ff497a
|
@ -147,7 +147,7 @@ contract AdminStuffs is Helper {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
contract SplitHelper is Helper {
|
contract SplitHelper is AdminStuffs {
|
||||||
|
|
||||||
function getBest(address src, address dest, uint srcAmt) public view returns (uint bestExchange, uint destAmt) {
|
function getBest(address src, address dest, uint srcAmt) public view returns (uint bestExchange, uint destAmt) {
|
||||||
uint finalSrcAmt = srcAmt;
|
uint finalSrcAmt = srcAmt;
|
||||||
|
@ -252,6 +252,9 @@ contract SplitResolver is SplitHelper {
|
||||||
} else {
|
} else {
|
||||||
destAmt += swapUniswap(daiAddr, ethAddr, srcAmt);
|
destAmt += swapUniswap(daiAddr, ethAddr, srcAmt);
|
||||||
}
|
}
|
||||||
|
TokenInterface wethContract = TokenInterface(wethAddr);
|
||||||
|
uint balanceWeth = wethContract.balanceOf(address(this));
|
||||||
|
wethContract.withdraw(balanceWeth);
|
||||||
} else {
|
} else {
|
||||||
TokenInterface wethContract = TokenInterface(wethAddr);
|
TokenInterface wethContract = TokenInterface(wethAddr);
|
||||||
uint balanceWeth = wethContract.balanceOf(address(this));
|
uint balanceWeth = wethContract.balanceOf(address(this));
|
||||||
|
@ -280,7 +283,7 @@ contract SplitResolver is SplitHelper {
|
||||||
address(this),
|
address(this),
|
||||||
2**255,
|
2**255,
|
||||||
0,
|
0,
|
||||||
admin
|
adminOne
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user