Revert WETH fix on receiver

This commit is contained in:
Thrilok Kumar 2021-04-21 21:54:21 +05:30
parent 87f884ce48
commit 507871cbdd
2 changed files with 2 additions and 14 deletions

View File

@ -100,9 +100,4 @@ interface AaveInterface {
interface InstaListInterface {
function accountID(address) external view returns (uint);
}
interface WETHTokenInterface {
function deposit(address user, bytes memory depositData) external payable;
}
}

View File

@ -4,7 +4,7 @@ pragma experimental ABIEncoderV2;
import { SafeERC20 } from "@openzeppelin/contracts/token/ERC20/SafeERC20.sol";
import { IERC20 } from "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import { TokenInterface } from "../../common/interfaces.sol";
import { AccountInterface, AaveData, AaveInterface, IndexInterface, WETHTokenInterface } from "./interfaces.sol";
import { AccountInterface, AaveData, AaveInterface, IndexInterface } from "./interfaces.sol";
import { Events } from "./events.sol";
import { Helpers } from "./helpers.sol";
@ -57,13 +57,6 @@ contract MigrateResolver is Helpers, Events {
}
}
if (_token == wethAddr) {
TokenInterface wethPosContract = TokenInterface(wethPosAddr);
if (wethPosContract.balanceOf(address(this)) > 0) {
WETHTokenInterface(wethAddr).deposit(address(this), abi.encode(wethPosContract.balanceOf(address(this))));
}
}
IERC20 _tokenContract = IERC20(_token);
uint _tokenBal = _tokenContract.balanceOf(address(this));
if (_tokenBal > 0) {