mirror of
https://github.com/Instadapp/dsa-polygon-migration.git
synced 2024-07-29 22:27:58 +00:00
Revert WETH fix on receiver
This commit is contained in:
parent
87f884ce48
commit
507871cbdd
|
@ -100,9 +100,4 @@ interface AaveInterface {
|
||||||
|
|
||||||
interface InstaListInterface {
|
interface InstaListInterface {
|
||||||
function accountID(address) external view returns (uint);
|
function accountID(address) external view returns (uint);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
interface WETHTokenInterface {
|
|
||||||
function deposit(address user, bytes memory depositData) external payable;
|
|
||||||
}
|
|
|
@ -4,7 +4,7 @@ pragma experimental ABIEncoderV2;
|
||||||
import { SafeERC20 } from "@openzeppelin/contracts/token/ERC20/SafeERC20.sol";
|
import { SafeERC20 } from "@openzeppelin/contracts/token/ERC20/SafeERC20.sol";
|
||||||
import { IERC20 } from "@openzeppelin/contracts/token/ERC20/IERC20.sol";
|
import { IERC20 } from "@openzeppelin/contracts/token/ERC20/IERC20.sol";
|
||||||
import { TokenInterface } from "../../common/interfaces.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 { Events } from "./events.sol";
|
||||||
import { Helpers } from "./helpers.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);
|
IERC20 _tokenContract = IERC20(_token);
|
||||||
uint _tokenBal = _tokenContract.balanceOf(address(this));
|
uint _tokenBal = _tokenContract.balanceOf(address(this));
|
||||||
if (_tokenBal > 0) {
|
if (_tokenBal > 0) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user