removed referral param

This commit is contained in:
bhavik-m 2022-03-07 01:00:45 +05:30
parent cb89771f7e
commit 2d308f2e35
4 changed files with 7 additions and 12 deletions

View File

@ -1,10 +1,5 @@
pragma solidity ^0.7.0;
contract Events {
event LogDeposit(
uint256 Amt,
address referral,
uint256 getId,
uint256 setId
);
event LogDeposit(uint256 Amt, uint256 getId, uint256 setId);
}

View File

@ -6,5 +6,7 @@ import { ILido } from "./interface.sol";
abstract contract Helpers {
ILido internal constant lidoInterface =
ILido(0xae7ab96520DE3A18E5e111B5EaAb095312D7fE84);
address treasury = 0x28849D2b63fA8D361e5fc15cB8aBB13019884d09; // Instadapp's treasury address
}
//0xC7B5aF82B05Eb3b64F12241B04B2cF14469E39F7

View File

@ -15,13 +15,11 @@ abstract contract Resolver is Events, DSMath, Basic, Helpers {
* @dev deposit ETH into Lido.
* @notice sends Eth into lido and in return you get equivalent of stEth tokens
* @param amt The amount of ETH to deposit. (For max: `uint256(-1)`)
* @param referral optional referral parameter
* @param getId ID to retrieve amt.
* @param setId ID stores the amount of ETH deposited.
*/
function deposit(
uint256 amt,
address referral,
uint256 getId,
uint256 setId
)
@ -32,11 +30,11 @@ abstract contract Resolver is Events, DSMath, Basic, Helpers {
uint256 _amt = getUint(getId, amt);
_amt = _amt == uint256(-1) ? address(this).balance : _amt;
lidoInterface.submit{ value: amt }(referral);
lidoInterface.submit{ value: amt }(treasury);
setUint(setId, _amt);
_eventName = "LogDeposit(uint256,address,uint256,uint256)";
_eventParam = abi.encode(_amt, referral, getId, setId);
_eventName = "LogDeposit(uint256,uint256,uint256)";
_eventParam = abi.encode(_amt, getId, setId);
}
}

View File

@ -85,7 +85,7 @@ describe("LidoStEth", function() {
{
connector: connectorName,
method: "deposit",
args: [_amt,"0x0000000000000000000000000000000000000000",0,0]
args: [_amt,0,0]
},
];
const tx = await dsaWallet0