Contract
0x9F11691FA842856E44586380b27Ac331ab7De93d
5
Contract Overview
Balance:
0 MATIC
My Name Tag:
Not Available
Txn Hash |
Method
|
Block
|
From
|
To
|
Value | [Txn Fee] | |||
---|---|---|---|---|---|---|---|---|---|
0x8735e8d472418bb1177288052602e12664a430bf40b6f2a0f7f937ef3973f887 | 0x60a06040 | 25550802 | 373 days 3 hrs ago | 0x1ff808e34e4df60326a3fc4c2b0f80748a3d60c2 | IN | Create: Converter | 0 MATIC | 0.023840260002 |
[ Download CSV Export ]
Contract Name:
Converter
Compiler Version
v0.8.7+commit.e28d00a7
Optimization Enabled:
Yes with 999999 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol"; import "@openzeppelin/contracts/security/ReentrancyGuard.sol"; import "./TokenPaymentSplitter.sol"; interface IUniswapV2Router02 { function swapExactTokensForTokensSupportingFeeOnTransferTokens( uint256 amountIn, uint256 amountOutMin, address[] calldata path, address to, uint256 deadline ) external; } /** * @title AirSwap Converter: Convert Fee Tokens * @notice https://www.airswap.io/ */ contract Converter is Ownable, ReentrancyGuard, TokenPaymentSplitter { using SafeERC20 for IERC20; address public wETH; address public swapToToken; address public immutable uniRouter; uint256 public triggerFee; mapping(address => address[]) private tokenPathMapping; event ConvertAndTransfer( address triggerAccount, address swapFromToken, address swapToToken, uint256 amountTokenFrom, uint256 amountTokenTo, address[] recievedAddresses ); event DrainTo(address[] tokens, address dest); constructor( address _wETH, address _swapToToken, address _uniRouter, uint256 _triggerFee, address[] memory _payees, uint256[] memory _shares ) TokenPaymentSplitter(_payees, _shares) { wETH = _wETH; swapToToken = _swapToToken; uniRouter = _uniRouter; setTriggerFee(_triggerFee); } /** * @dev Set a new address for WETH. **/ function setWETH(address _swapWETH) public onlyOwner { require(_swapWETH != address(0), "MUST_BE_VALID_ADDRESS"); wETH = _swapWETH; } /** * @dev Set a new token to swap to (e.g., stabletoken). **/ function setSwapToToken(address _swapToToken) public onlyOwner { require(_swapToToken != address(0), "MUST_BE_VALID_ADDRESS"); swapToToken = _swapToToken; } /** * @dev Set a new fee (perentage 0 - 100) for calling the ConvertAndTransfer function. */ function setTriggerFee(uint256 _triggerFee) public onlyOwner { require(_triggerFee <= 100, "FEE_TOO_HIGH"); triggerFee = _triggerFee; } /** * @dev Set a new Uniswap router path for a token. */ function setTokenPath(address _token, address[] memory _tokenPath) public onlyOwner { uint256 pathLength = _tokenPath.length; for (uint256 i = 0; i < pathLength; i++) { tokenPathMapping[_token].push(_tokenPath[i]); } } /** * @dev Converts an token in the contract to the SwapToToken and transfers to payees. * @param _swapFromToken The token to be swapped from. * @param _amountOutMin The amount to be swapped and distributed. */ function convertAndTransfer(address _swapFromToken, uint256 _amountOutMin) public onlyOwner nonReentrant { // Checks that at least 1 payee is set to recieve converted token. require(_payees.length >= 1, "PAYEES_MUST_BE_SET"); // Checks that _amountOutMin is at least 1 require(_amountOutMin > 0, "INVALID_AMOUNT_OUT"); // Calls the balanceOf function from the to be converted token. uint256 tokenBalance = _balanceOfErc20(_swapFromToken); // Checks that the converted token is currently present in the contract. require(tokenBalance > 0, "NO_BALANCE_TO_CONVERT"); // Read or set the path for AMM. if (_swapFromToken != swapToToken) { address[] memory path; if (tokenPathMapping[_swapFromToken].length > 0) { path = getTokenPath(_swapFromToken); } else { tokenPathMapping[_swapFromToken].push(_swapFromToken); tokenPathMapping[_swapFromToken].push(wETH); if (swapToToken != wETH) { tokenPathMapping[_swapFromToken].push(swapToToken); } path = getTokenPath(_swapFromToken); } // Approve token for AMM usage. IERC20(_swapFromToken).safeIncreaseAllowance(uniRouter, tokenBalance); // Calls the swap function from the on-chain AMM to swap token from fee pool into reward token. IUniswapV2Router02(uniRouter) .swapExactTokensForTokensSupportingFeeOnTransferTokens( tokenBalance, _amountOutMin, path, address(this), block.timestamp ); } // Calls the balanceOf function from the reward token to get the new balance post-swap. uint256 totalPayeeAmount = _balanceOfErc20(swapToToken); // Calculates trigger reward amount and transfers to msg.sender. if (triggerFee > 0) { uint256 triggerFeeAmount = (totalPayeeAmount * triggerFee) / 100; _transferErc20(msg.sender, swapToToken, triggerFeeAmount); totalPayeeAmount = totalPayeeAmount - triggerFeeAmount; } // Transfers remaining amount to reward payee address(es). for (uint256 i = 0; i < _payees.length; i++) { uint256 payeeAmount = (totalPayeeAmount * _shares[_payees[i]]) / _totalShares; _transferErc20(_payees[i], swapToToken, payeeAmount); } emit ConvertAndTransfer( msg.sender, _swapFromToken, swapToToken, tokenBalance, totalPayeeAmount, _payees ); } /** * @dev Drains funds from provided list of tokens * @param _transferTo Address of the recipient. * @param _tokens List of tokens to transfer from the contract */ function drainTo(address _transferTo, address[] calldata _tokens) public onlyOwner { for (uint256 i = 0; i < _tokens.length; i++) { uint256 balance = _balanceOfErc20(_tokens[i]); if (balance > 0) { _transferErc20(_transferTo, _tokens[i], balance); } } emit DrainTo(_tokens, _transferTo); } /** * @dev Add a recipient to receive payouts from the consolidateFeeToken function. * @param _account Address of the recipient. * @param _shares Amount of shares to determine th proportion of payout received. */ function addPayee(address _account, uint256 _shares) public onlyOwner { _addPayee(_account, _shares); } /** * @dev Remove a recipient from receiving payouts from the consolidateFeeToken function. * @param _account Address of the recipient. * @param _index Index number of the recipient in the array of recipients. */ function removePayee(address _account, uint256 _index) public onlyOwner { _removePayee(_account, _index); } /** * @dev View Uniswap router path for a token. */ function getTokenPath(address _token) public view onlyOwner returns (address[] memory) { return tokenPathMapping[_token]; } /** * @dev Internal function to transfer ERC20 held in the contract. * @param _recipient Address to receive ERC20. * @param _tokenContract Address of the ERC20. * @param _transferAmount Amount or ERC20 to be transferred. * * */ function _transferErc20( address _recipient, address _tokenContract, uint256 _transferAmount ) internal { IERC20(_tokenContract).safeTransfer(_recipient, _transferAmount); } /** * @dev Internal function to call balanceOf on ERC20. * @param _tokenToBalanceOf Address of ERC20 to call. * * */ function _balanceOfErc20(address _tokenToBalanceOf) internal view returns (uint256) { IERC20 erc; erc = IERC20(_tokenToBalanceOf); uint256 tokenBalance = erc.balanceOf(address(this)); return tokenBalance; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (access/Ownable.sol) pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _transferOwnership(_msgSender()); } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { require(owner() == _msgSender(), "Ownable: caller is not the owner"); _; } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC20/utils/SafeERC20.sol) pragma solidity ^0.8.0; import "../IERC20.sol"; import "../../../utils/Address.sol"; /** * @title SafeERC20 * @dev Wrappers around ERC20 operations that throw on failure (when the token * contract returns false). Tokens that return no value (and instead revert or * throw on failure) are also supported, non-reverting calls are assumed to be * successful. * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract, * which allows you to call the safe operations as `token.safeTransfer(...)`, etc. */ library SafeERC20 { using Address for address; function safeTransfer( IERC20 token, address to, uint256 value ) internal { _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value)); } function safeTransferFrom( IERC20 token, address from, address to, uint256 value ) internal { _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value)); } /** * @dev Deprecated. This function has issues similar to the ones found in * {IERC20-approve}, and its usage is discouraged. * * Whenever possible, use {safeIncreaseAllowance} and * {safeDecreaseAllowance} instead. */ function safeApprove( IERC20 token, address spender, uint256 value ) internal { // safeApprove should only be called when setting an initial allowance, // or when resetting it to zero. To increase and decrease it, use // 'safeIncreaseAllowance' and 'safeDecreaseAllowance' require( (value == 0) || (token.allowance(address(this), spender) == 0), "SafeERC20: approve from non-zero to non-zero allowance" ); _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value)); } function safeIncreaseAllowance( IERC20 token, address spender, uint256 value ) internal { uint256 newAllowance = token.allowance(address(this), spender) + value; _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } function safeDecreaseAllowance( IERC20 token, address spender, uint256 value ) internal { unchecked { uint256 oldAllowance = token.allowance(address(this), spender); require(oldAllowance >= value, "SafeERC20: decreased allowance below zero"); uint256 newAllowance = oldAllowance - value; _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } } /** * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement * on the return value: the return value is optional (but if data is returned, it must not be false). * @param token The token targeted by the call. * @param data The call data (encoded using abi.encode or one of its variants). */ function _callOptionalReturn(IERC20 token, bytes memory data) private { // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since // we're implementing it ourselves. We use {Address.functionCall} to perform this call, which verifies that // the target address contains contract code and also asserts for success in the low-level call. bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed"); if (returndata.length > 0) { // Return data is optional require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed"); } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (security/ReentrancyGuard.sol) pragma solidity ^0.8.0; /** * @dev Contract module that helps prevent reentrant calls to a function. * * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier * available, which can be applied to functions to make sure there are no nested * (reentrant) calls to them. * * Note that because there is a single `nonReentrant` guard, functions marked as * `nonReentrant` may not call one another. This can be worked around by making * those functions `private`, and then adding `external` `nonReentrant` entry * points to them. * * TIP: If you would like to learn more about reentrancy and alternative ways * to protect against it, check out our blog post * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul]. */ abstract contract ReentrancyGuard { // Booleans are more expensive than uint256 or any type that takes up a full // word because each write operation emits an extra SLOAD to first read the // slot's contents, replace the bits taken up by the boolean, and then write // back. This is the compiler's defense against contract upgrades and // pointer aliasing, and it cannot be disabled. // The values being non-zero value makes deployment a bit more expensive, // but in exchange the refund on every call to nonReentrant will be lower in // amount. Since refunds are capped to a percentage of the total // transaction's gas, it is best to keep them low in cases like this one, to // increase the likelihood of the full refund coming into effect. uint256 private constant _NOT_ENTERED = 1; uint256 private constant _ENTERED = 2; uint256 private _status; constructor() { _status = _NOT_ENTERED; } /** * @dev Prevents a contract from calling itself, directly or indirectly. * Calling a `nonReentrant` function from another `nonReentrant` * function is not supported. It is possible to prevent this from happening * by making the `nonReentrant` function external, and making it call a * `private` function that does the actual work. */ modifier nonReentrant() { // On the first call to nonReentrant, _notEntered will be true require(_status != _ENTERED, "ReentrancyGuard: reentrant call"); // Any calls to nonReentrant after this point will fail _status = _ENTERED; _; // By storing the original value once again, a refund is triggered (see // https://eips.ethereum.org/EIPS/eip-2200) _status = _NOT_ENTERED; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/utils/Address.sol"; import "@openzeppelin/contracts/utils/Context.sol"; /** * @title TokenPaymentSplitter * @dev Modified version of OpenZeppelin's PaymentSplitter contract. This contract allows to split Token payments * among a group of accounts. The sender does not need to be aware that the Token will be split in this way, since * it is handled transparently by the contract. * * The split can be in equal parts or in any other arbitrary proportion. The way this is specified is by assigning each * account to a number of shares. * * The actual transfer is triggered as a separate function. */ abstract contract TokenPaymentSplitter is Context { uint256 internal _totalShares; mapping(address => uint256) internal _shares; address[] internal _payees; event PayeeAdded(address account, uint256 shares); event PayeeRemoved(address account); /** * @dev Creates an instance of `TokenPaymentSplitter` where each account in `payees` is assigned the number * of shares at the matching position in the `shares` array. * * All addresses in `payees` must be non-zero. Both arrays must have the same non-zero length, and there must be no * duplicates in `payees`. */ constructor(address[] memory payees, uint256[] memory shares_) payable { require( payees.length == shares_.length, "TokenPaymentSplitter: payees and shares length mismatch" ); require(payees.length > 0, "TokenPaymentSplitter: no payees"); for (uint256 i = 0; i < payees.length; i++) { _addPayee(payees[i], shares_[i]); } } /** * @dev Getter for the total shares held by payees. */ function totalShares() public view returns (uint256) { return _totalShares; } /** * @dev Getter for the amount of shares held by an account. */ function shares(address account) public view returns (uint256) { return _shares[account]; } /** * @dev Getter for the address of the payee number `index`. */ function payee(uint256 index) public view returns (address) { require(_payees.length >= 1, "TokenPaymentSplitter: There are no payees"); return _payees[index]; } /** * @dev Add a new payee to the contract. * @param account The address of the payee to add. * @param shares_ The number of shares owned by the payee. */ function _addPayee(address account, uint256 shares_) internal { require( account != address(0), "TokenPaymentSplitter: account is the zero address" ); require(shares_ > 0, "TokenPaymentSplitter: shares are 0"); require( _shares[account] == 0, "TokenPaymentSplitter: account already has shares" ); _payees.push(account); _shares[account] = shares_; _totalShares = _totalShares + shares_; emit PayeeAdded(account, shares_); } /** * @dev Remove an existing payee from the contract. * @param account The address of the payee to remove. * @param index The position of the payee in the _payees array. */ function _removePayee(address account, uint256 index) internal { require( index < _payees.length, "TokenPaymentSplitter: index not in payee array" ); require( account == _payees[index], "TokenPaymentSplitter: account does not match payee array index" ); _totalShares = _totalShares - _shares[account]; _shares[account] = 0; _payees[index] = _payees[_payees.length - 1]; _payees.pop(); emit PayeeRemoved(account); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC20/IERC20.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address recipient, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an {Approval} event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `sender` to `recipient` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom( address sender, address recipient, uint256 amount ) external returns (bool); /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Address.sol) pragma solidity ^0.8.0; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize, which returns 0 for contracts in // construction, since the code is only stored at the end of the // constructor execution. uint256 size; assembly { size := extcodesize(account) } return size > 0; } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { require(isContract(target), "Address: delegate call to non-contract"); (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason using the provided one. * * _Available since v4.3._ */ function verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) internal pure returns (bytes memory) { if (success) { return returndata; } else { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
{ "optimizer": { "enabled": true, "runs": 999999 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
[{"inputs":[{"internalType":"address","name":"_wETH","type":"address"},{"internalType":"address","name":"_swapToToken","type":"address"},{"internalType":"address","name":"_uniRouter","type":"address"},{"internalType":"uint256","name":"_triggerFee","type":"uint256"},{"internalType":"address[]","name":"_payees","type":"address[]"},{"internalType":"uint256[]","name":"_shares","type":"uint256[]"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"triggerAccount","type":"address"},{"indexed":false,"internalType":"address","name":"swapFromToken","type":"address"},{"indexed":false,"internalType":"address","name":"swapToToken","type":"address"},{"indexed":false,"internalType":"uint256","name":"amountTokenFrom","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amountTokenTo","type":"uint256"},{"indexed":false,"internalType":"address[]","name":"recievedAddresses","type":"address[]"}],"name":"ConvertAndTransfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address[]","name":"tokens","type":"address[]"},{"indexed":false,"internalType":"address","name":"dest","type":"address"}],"name":"DrainTo","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"shares","type":"uint256"}],"name":"PayeeAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"PayeeRemoved","type":"event"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"uint256","name":"_shares","type":"uint256"}],"name":"addPayee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_swapFromToken","type":"address"},{"internalType":"uint256","name":"_amountOutMin","type":"uint256"}],"name":"convertAndTransfer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_transferTo","type":"address"},{"internalType":"address[]","name":"_tokens","type":"address[]"}],"name":"drainTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"getTokenPath","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"payee","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"uint256","name":"_index","type":"uint256"}],"name":"removePayee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_swapToToken","type":"address"}],"name":"setSwapToToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"address[]","name":"_tokenPath","type":"address[]"}],"name":"setTokenPath","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_triggerFee","type":"uint256"}],"name":"setTriggerFee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_swapWETH","type":"address"}],"name":"setWETH","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"shares","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"swapToToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalShares","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"triggerFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"uniRouter","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"wETH","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
60a06040523480156200001157600080fd5b5060405162002e1b38038062002e1b83398101604081905262000034916200056a565b81816200004133620001dd565b600180558051825114620000c25760405162461bcd60e51b815260206004820152603760248201527f546f6b656e5061796d656e7453706c69747465723a2070617965657320616e6460448201527f20736861726573206c656e677468206d69736d6174636800000000000000000060648201526084015b60405180910390fd5b6000825111620001155760405162461bcd60e51b815260206004820152601f60248201527f546f6b656e5061796d656e7453706c69747465723a206e6f20706179656573006044820152606401620000b9565b60005b825181101562000181576200016c8382815181106200013b576200013b6200072a565b60200260200101518383815181106200015857620001586200072a565b60200260200101516200022d60201b60201c565b806200017881620006f6565b91505062000118565b5050600580546001600160a01b03808a166001600160a01b0319928316179092556006805492891692909116919091179055506001600160601b0319606085901b16608052620001d18362000430565b50505050505062000756565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6001600160a01b0382166200029f5760405162461bcd60e51b815260206004820152603160248201527f546f6b656e5061796d656e7453706c69747465723a206163636f756e7420697360448201527020746865207a65726f206164647265737360781b6064820152608401620000b9565b60008111620002fc5760405162461bcd60e51b815260206004820152602260248201527f546f6b656e5061796d656e7453706c69747465723a2073686172657320617265604482015261020360f41b6064820152608401620000b9565b6001600160a01b038216600090815260036020526040902054156200037d5760405162461bcd60e51b815260206004820152603060248201527f546f6b656e5061796d656e7453706c69747465723a206163636f756e7420616c60448201526f7265616479206861732073686172657360801b6064820152608401620000b9565b60048054600181019091557f8a35acfbc15ff81a39ae7d344fd709f28e8600b4aa8c65c6b64bfe7fe36bd19b0180546001600160a01b0319166001600160a01b0384169081179091556000908152600360205260409020819055600254620003e7908290620006db565b600255604080516001600160a01b0384168152602081018390527f40c340f65e17194d14ddddb073d3c9f888e3cb52b5aae0c6c7706b4fbc905fac910160405180910390a15050565b6000546001600160a01b031633146200048c5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401620000b9565b6064811115620004ce5760405162461bcd60e51b815260206004820152600c60248201526b08c8a8abea89e9ebe90928e960a31b6044820152606401620000b9565b600755565b80516001600160a01b0381168114620004eb57600080fd5b919050565b600082601f8301126200050257600080fd5b815160206200051b6200051583620006b5565b62000682565b80838252828201915082860187848660051b89010111156200053c57600080fd5b60005b858110156200055d578151845292840192908401906001016200053f565b5090979650505050505050565b60008060008060008060c087890312156200058457600080fd5b6200058f87620004d3565b95506020620005a0818901620004d3565b9550620005b060408901620004d3565b606089015160808a015191965094506001600160401b0380821115620005d557600080fd5b818a0191508a601f830112620005ea57600080fd5b8151620005fb6200051582620006b5565b8082825285820191508585018e878560051b88010111156200061c57600080fd5b600095505b838610156200064a576200063581620004d3565b83526001959095019491860191860162000621565b5060a08d015190975094505050808311156200066557600080fd5b50506200067589828a01620004f0565b9150509295509295509295565b604051601f8201601f191681016001600160401b0381118282101715620006ad57620006ad62000740565b604052919050565b60006001600160401b03821115620006d157620006d162000740565b5060051b60200190565b60008219821115620006f157620006f162000714565b500190565b60006000198214156200070d576200070d62000714565b5060010190565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b60805160601c612698620007836000396000818161028401528181610b2c0152610b8e01526126986000f3fe608060405234801561001057600080fd5b50600436106101515760003560e01c806384e45c3d116100cd578063bde6ad0711610081578063f242862111610066578063f242862114610302578063f2fde38b14610322578063f68371571461033557600080fd5b8063bde6ad07146102b9578063ce7c2ac2146102cc57600080fd5b80638da5cb5b116100b25780638da5cb5b14610261578063a0e47bf61461027f578063b21285ce146102a657600080fd5b806384e45c3d1461023b5780638b83209b1461024e57600080fd5b80636a0c287a11610124578063715018a611610109578063715018a6146101db57806373b411cb146101e357806376aa3fef1461022857600080fd5b80636a0c287a146101a85780636a80d4ee146101c857600080fd5b806318f9b023146101565780631fc810c41461016b5780633a98ef391461017e5780635b769f3c14610195575b600080fd5b6101696101643660046121fd565b61033e565b005b610169610179366004612100565b6103d2565b6002545b6040519081526020015b60405180910390f35b6101696101a336600461205f565b610511565b6101bb6101b636600461205f565b610656565b60405161018c91906123ed565b6101696101d63660046121fd565b610769565b610169610db2565b6006546102039073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161018c565b610169610236366004612249565b610e3f565b6101696102493660046121fd565b610f30565b61020361025c366004612249565b610fbb565b60005473ffffffffffffffffffffffffffffffffffffffff16610203565b6102037f000000000000000000000000000000000000000000000000000000000000000081565b6101696102b436600461205f565b61108c565b6101696102c736600461207a565b6111d1565b6101826102da36600461205f565b73ffffffffffffffffffffffffffffffffffffffff1660009081526003602052604090205490565b6005546102039073ffffffffffffffffffffffffffffffffffffffff1681565b61016961033036600461205f565b61131b565b61018260075481565b60005473ffffffffffffffffffffffffffffffffffffffff1633146103c4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064015b60405180910390fd5b6103ce828261144b565b5050565b60005473ffffffffffffffffffffffffffffffffffffffff163314610453576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103bb565b805160005b8181101561050b5773ffffffffffffffffffffffffffffffffffffffff84166000908152600860205260409020835184908390811061049957610499612604565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055806105038161256d565b915050610458565b50505050565b60005473ffffffffffffffffffffffffffffffffffffffff163314610592576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103bb565b73ffffffffffffffffffffffffffffffffffffffff811661060f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4d5553545f42455f56414c49445f41444452455353000000000000000000000060448201526064016103bb565b600580547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b60005460609073ffffffffffffffffffffffffffffffffffffffff1633146106da576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103bb565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600860209081526040918290208054835181840281018401909452808452909183018282801561075c57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610731575b505050505090505b919050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146107ea576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103bb565b60026001541415610857576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064016103bb565b6002600190815560045410156108c9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f5041594545535f4d5553545f42455f534554000000000000000000000000000060448201526064016103bb565b60008111610933576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f494e56414c49445f414d4f554e545f4f5554000000000000000000000000000060448201526064016103bb565b600061093e83611715565b9050600081116109aa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4e4f5f42414c414e43455f544f5f434f4e56455254000000000000000000000060448201526064016103bb565b60065473ffffffffffffffffffffffffffffffffffffffff848116911614610bff5773ffffffffffffffffffffffffffffffffffffffff831660009081526008602052604090205460609015610a0a57610a0384610656565b9050610b10565b73ffffffffffffffffffffffffffffffffffffffff8085166000818152600860209081526040822080546001818101835582855292842090810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000908116909617905560058054835494850184559290945291909101805490931690841617909155546006548216911614610b045773ffffffffffffffffffffffffffffffffffffffff8085166000908152600860209081526040822060065481546001810183559184529190922090910180547fffffffffffffffffffffffff000000000000000000000000000000000000000016919092161790555b610b0d84610656565b90505b610b5173ffffffffffffffffffffffffffffffffffffffff85167f0000000000000000000000000000000000000000000000000000000000000000846117c1565b6040517f5c11d79500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001690635c11d79590610bcb9085908790869030904290600401612451565b600060405180830381600087803b158015610be557600080fd5b505af1158015610bf9573d6000803e3d6000fd5b50505050505b600654600090610c249073ffffffffffffffffffffffffffffffffffffffff16611715565b60075490915015610c81576000606460075483610c4191906124ed565b610c4b91906124b2565b600654909150610c7390339073ffffffffffffffffffffffffffffffffffffffff168361194c565b610c7d818361252a565b9150505b60005b600454811015610d4a5760006002546003600060048581548110610caa57610caa612604565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff168352820192909252604001902054610ce690856124ed565b610cf091906124b2565b9050610d3760048381548110610d0857610d08612604565b60009182526020909120015460065473ffffffffffffffffffffffffffffffffffffffff91821691168361194c565b5080610d428161256d565b915050610c84565b506006546040517fbbff0d48cf418ade2cf203bbc04beecbb9959c8f7df1b4d3dcea3233e29a058a91610da0913391889173ffffffffffffffffffffffffffffffffffffffff90911690879087906004906122e8565b60405180910390a15050600180555050565b60005473ffffffffffffffffffffffffffffffffffffffff163314610e33576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103bb565b610e3d6000611972565b565b60005473ffffffffffffffffffffffffffffffffffffffff163314610ec0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103bb565b6064811115610f2b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f4645455f544f4f5f48494748000000000000000000000000000000000000000060448201526064016103bb565b600755565b60005473ffffffffffffffffffffffffffffffffffffffff163314610fb1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103bb565b6103ce82826119e7565b60045460009060011115611051576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602960248201527f546f6b656e5061796d656e7453706c69747465723a205468657265206172652060448201527f6e6f20706179656573000000000000000000000000000000000000000000000060648201526084016103bb565b6004828154811061106457611064612604565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1692915050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461110d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103bb565b73ffffffffffffffffffffffffffffffffffffffff811661118a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4d5553545f42455f56414c49445f41444452455353000000000000000000000060448201526064016103bb565b600680547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b60005473ffffffffffffffffffffffffffffffffffffffff163314611252576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103bb565b60005b818110156112da57600061128e84848481811061127457611274612604565b9050602002016020810190611289919061205f565b611715565b905080156112c7576112c7858585858181106112ac576112ac612604565b90506020020160208101906112c1919061205f565b8361194c565b50806112d28161256d565b915050611255565b507f4b713dd63c7c270b811762a754d42e5d79ea1ba9d3a0899d73eab3e38b50cd6f82828560405161130e93929190612375565b60405180910390a1505050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461139c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103bb565b73ffffffffffffffffffffffffffffffffffffffff811661143f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084016103bb565b61144881611972565b50565b73ffffffffffffffffffffffffffffffffffffffff82166114ee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603160248201527f546f6b656e5061796d656e7453706c69747465723a206163636f756e7420697360448201527f20746865207a65726f206164647265737300000000000000000000000000000060648201526084016103bb565b6000811161157e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f546f6b656e5061796d656e7453706c69747465723a207368617265732061726560448201527f203000000000000000000000000000000000000000000000000000000000000060648201526084016103bb565b73ffffffffffffffffffffffffffffffffffffffff821660009081526003602052604090205415611631576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f546f6b656e5061796d656e7453706c69747465723a206163636f756e7420616c60448201527f726561647920686173207368617265730000000000000000000000000000000060648201526084016103bb565b60048054600181019091557f8a35acfbc15ff81a39ae7d344fd709f28e8600b4aa8c65c6b64bfe7fe36bd19b0180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff841690811790915560009081526003602052604090208190556002546116be90829061249a565b6002556040805173ffffffffffffffffffffffffffffffffffffffff84168152602081018390527f40c340f65e17194d14ddddb073d3c9f888e3cb52b5aae0c6c7706b4fbc905fac91015b60405180910390a15050565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000908290829073ffffffffffffffffffffffffffffffffffffffff8316906370a082319060240160206040518083038186803b15801561178157600080fd5b505afa158015611795573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117b99190612262565b949350505050565b6040517fdd62ed3e00000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff8381166024830152600091839186169063dd62ed3e9060440160206040518083038186803b15801561183357600080fd5b505afa158015611847573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061186b9190612262565b611875919061249a565b60405173ffffffffffffffffffffffffffffffffffffffff851660248201526044810182905290915061050b9085907f095ea7b300000000000000000000000000000000000000000000000000000000906064015b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611ced565b61196d73ffffffffffffffffffffffffffffffffffffffff83168483611df9565b505050565b6000805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6004548110611a78576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f546f6b656e5061796d656e7453706c69747465723a20696e646578206e6f742060448201527f696e20706179656520617272617900000000000000000000000000000000000060648201526084016103bb565b60048181548110611a8b57611a8b612604565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff838116911614611b3e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603e60248201527f546f6b656e5061796d656e7453706c69747465723a206163636f756e7420646f60448201527f6573206e6f74206d6174636820706179656520617272617920696e646578000060648201526084016103bb565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260036020526040902054600254611b71919061252a565b60025573ffffffffffffffffffffffffffffffffffffffff821660009081526003602052604081205560048054611baa9060019061252a565b81548110611bba57611bba612604565b6000918252602090912001546004805473ffffffffffffffffffffffffffffffffffffffff9092169183908110611bf357611bf3612604565b9060005260206000200160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506004805480611c4c57611c4c6125d5565b60008281526020908190207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff908301810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905590910190915560405173ffffffffffffffffffffffffffffffffffffffff841681527fc2ee819acfe1baf117c2aac9d3f627a864f075d2fecc990eebd82d59f26626059101611709565b6000611d4f826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff16611e4f9092919063ffffffff16565b80519091501561196d5780806020019051810190611d6d9190612227565b61196d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016103bb565b60405173ffffffffffffffffffffffffffffffffffffffff831660248201526044810182905261196d9084907fa9059cbb00000000000000000000000000000000000000000000000000000000906064016118ca565b6060611e5e8484600085611e68565b90505b9392505050565b606082471015611efa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016103bb565b843b611f62576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016103bb565b6000808673ffffffffffffffffffffffffffffffffffffffff168587604051611f8b91906122cc565b60006040518083038185875af1925050503d8060008114611fc8576040519150601f19603f3d011682016040523d82523d6000602084013e611fcd565b606091505b5091509150611fdd828286611fe8565b979650505050505050565b60608315611ff7575081611e61565b8251156120075782518084602001fd5b816040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016103bb9190612400565b803573ffffffffffffffffffffffffffffffffffffffff8116811461076457600080fd5b60006020828403121561207157600080fd5b611e618261203b565b60008060006040848603121561208f57600080fd5b6120988461203b565b9250602084013567ffffffffffffffff808211156120b557600080fd5b818601915086601f8301126120c957600080fd5b8135818111156120d857600080fd5b8760208260051b85010111156120ed57600080fd5b6020830194508093505050509250925092565b6000806040838503121561211357600080fd5b61211c8361203b565b915060208084013567ffffffffffffffff8082111561213a57600080fd5b818601915086601f83011261214e57600080fd5b81358181111561216057612160612633565b8060051b6040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0603f830116810181811085821117156121a3576121a3612633565b604052828152858101935084860182860187018b10156121c257600080fd5b600095505b838610156121ec576121d88161203b565b8552600195909501949386019386016121c7565b508096505050505050509250929050565b6000806040838503121561221057600080fd5b6122198361203b565b946020939093013593505050565b60006020828403121561223957600080fd5b81518015158114611e6157600080fd5b60006020828403121561225b57600080fd5b5035919050565b60006020828403121561227457600080fd5b5051919050565b600081518084526020808501945080840160005b838110156122c157815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161228f565b509495945050505050565b600082516122de818460208701612541565b9190910192915050565b600060c0820173ffffffffffffffffffffffffffffffffffffffff808a1684526020818a1681860152818916604086015287606086015286608086015260c060a086015282865480855260e0870191508760005282600020945060005b81811015612363578554851683526001958601959284019201612345565b50909c9b505050505050505050505050565b6040808252810183905260008460608301825b868110156123c35773ffffffffffffffffffffffffffffffffffffffff6123ae8461203b565b16825260209283019290910190600101612388565b50809250505073ffffffffffffffffffffffffffffffffffffffff83166020830152949350505050565b602081526000611e61602083018461227b565b602081526000825180602084015261241f816040850160208701612541565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b85815284602082015260a06040820152600061247060a083018661227b565b73ffffffffffffffffffffffffffffffffffffffff94909416606083015250608001529392505050565b600082198211156124ad576124ad6125a6565b500190565b6000826124e8577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615612525576125256125a6565b500290565b60008282101561253c5761253c6125a6565b500390565b60005b8381101561255c578181015183820152602001612544565b8381111561050b5750506000910152565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82141561259f5761259f6125a6565b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fdfea264697066735822122040da336282fc55be116a6ee6c79a2afa663e62ce06fa23c7a7b4b5d46ae8daa264736f6c63430008070033000000000000000000000000a6fa4fb5f76172d178d61b04b0ecd319c5d1c0aa000000000000000000000000a6fa4fb5f76172d178d61b04b0ecd319c5d1c0aa0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000010000000000000000000000009c7005fa2f8476e2331f45f69e0930a4c9eff0c300000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000064
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000a6fa4fb5f76172d178d61b04b0ecd319c5d1c0aa000000000000000000000000a6fa4fb5f76172d178d61b04b0ecd319c5d1c0aa0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000010000000000000000000000009c7005fa2f8476e2331f45f69e0930a4c9eff0c300000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000064
-----Decoded View---------------
Arg [0] : _wETH (address): 0xa6fa4fb5f76172d178d61b04b0ecd319c5d1c0aa
Arg [1] : _swapToToken (address): 0xa6fa4fb5f76172d178d61b04b0ecd319c5d1c0aa
Arg [2] : _uniRouter (address): 0x7a250d5630b4cf539739df2c5dacb4c659f2488d
Arg [3] : _triggerFee (uint256): 0
Arg [4] : _payees (address[]): 0x9c7005fa2f8476e2331f45f69e0930a4c9eff0c3
Arg [5] : _shares (uint256[]): 100
-----Encoded View---------------
10 Constructor Arguments found :
Arg [0] : 000000000000000000000000a6fa4fb5f76172d178d61b04b0ecd319c5d1c0aa
Arg [1] : 000000000000000000000000a6fa4fb5f76172d178d61b04b0ecd319c5d1c0aa
Arg [2] : 0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [4] : 00000000000000000000000000000000000000000000000000000000000000c0
Arg [5] : 0000000000000000000000000000000000000000000000000000000000000100
Arg [6] : 0000000000000000000000000000000000000000000000000000000000000001
Arg [7] : 0000000000000000000000009c7005fa2f8476e2331f45f69e0930a4c9eff0c3
Arg [8] : 0000000000000000000000000000000000000000000000000000000000000001
Arg [9] : 0000000000000000000000000000000000000000000000000000000000000064
Age | Block | Fee Address | BC Fee Address | Voting Power | Jailed | Incoming |
---|