ETH Price: $2,890.39 (+0.59%)
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Add Revenue123748552021-05-05 14:51:211282 days ago1620226281IN
0xD8E3A701...26927af07
0 ETH0.008846264
Add Revenue123748492021-05-05 14:50:351282 days ago1620226235IN
0xD8E3A701...26927af07
0 ETH0.008846264
Add Revenue123748012021-05-05 14:41:011282 days ago1620225661IN
0xD8E3A701...26927af07
0 ETH0.008292660
Add Revenue123747052021-05-05 14:20:111282 days ago1620224411IN
0xD8E3A701...26927af07
0 ETH0.0078793357
Add Revenue117960722021-02-05 11:53:111371 days ago1612525991IN
0xD8E3A701...26927af07
0 ETH0.01871467144
Add Revenue117960682021-02-05 11:52:371371 days ago1612525957IN
0xD8E3A701...26927af07
0 ETH0.01897459146
Add Revenue117960662021-02-05 11:52:301371 days ago1612525950IN
0xD8E3A701...26927af07
0 ETH0.01897459146
Add Revenue117960612021-02-05 11:51:061371 days ago1612525866IN
0xD8E3A701...26927af07
0 ETH0.02222162171
Add Revenue117532282021-01-29 21:35:081378 days ago1611956108IN
0xD8E3A701...26927af07
0 ETH0.02828298165
Add Revenue117522392021-01-29 17:50:401378 days ago1611942640IN
0xD8E3A701...26927af07
0 ETH0.00465244104
Add Revenue117522382021-01-29 17:50:361378 days ago1611942636IN
0xD8E3A701...26927af07
0 ETH0.01626684104
Add Revenue117522282021-01-29 17:48:161378 days ago1611942496IN
0xD8E3A701...26927af07
0 ETH0.01954096114
Add Revenue117522082021-01-29 17:43:351378 days ago1611942215IN
0xD8E3A701...26927af07
0 ETH0.0162656104
New Pool116544932021-01-14 17:12:521393 days ago1610644372IN
0xD8E3A701...26927af07
0 ETH0.170865660
Set Drain Addres...116159472021-01-08 19:19:331399 days ago1610133573IN
0xD8E3A701...26927af07
0 ETH0.00301103106
Set Drain Addres...116148832021-01-08 15:24:431399 days ago1610119483IN
0xD8E3A701...26927af07
0 ETH0.0056812200
New Pool116145692021-01-08 14:17:111399 days ago1610115431IN
0xD8E3A701...26927af07
0 ETH0.39868472140
New Pool116145242021-01-08 14:08:041399 days ago1610114884IN
0xD8E3A701...26927af07
0 ETH0.4556416160
New Pool116142462021-01-08 13:02:541399 days ago1610110974IN
0xD8E3A701...26927af07
0 ETH0.2862808100
0x60806040116141102021-01-08 12:32:121399 days ago1610109132IN
 Create: PoolController
0 ETH0.36551812105

Latest 25 internal transactions (View All)

Advanced mode:
Parent Transaction Hash Block From To
211217432024-11-05 13:27:472 days ago1730813267
0xD8E3A701...26927af07
0 ETH
211217432024-11-05 13:27:472 days ago1730813267
0xD8E3A701...26927af07
0 ETH
211217432024-11-05 13:27:472 days ago1730813267
0xD8E3A701...26927af07
0 ETH
211217432024-11-05 13:27:472 days ago1730813267
0xD8E3A701...26927af07
0 ETH
211217432024-11-05 13:27:472 days ago1730813267
0xD8E3A701...26927af07
0 ETH
211217432024-11-05 13:27:472 days ago1730813267
0xD8E3A701...26927af07
0 ETH
208347532024-09-26 12:20:5942 days ago1727353259
0xD8E3A701...26927af07
0 ETH
208347532024-09-26 12:20:5942 days ago1727353259
0xD8E3A701...26927af07
0 ETH
208347532024-09-26 12:20:5942 days ago1727353259
0xD8E3A701...26927af07
0 ETH
208347532024-09-26 12:20:5942 days ago1727353259
0xD8E3A701...26927af07
0 ETH
208347532024-09-26 12:20:5942 days ago1727353259
0xD8E3A701...26927af07
0 ETH
208343212024-09-26 10:54:2342 days ago1727348063
0xD8E3A701...26927af07
0 ETH
208343212024-09-26 10:54:2342 days ago1727348063
0xD8E3A701...26927af07
0 ETH
208343212024-09-26 10:54:2342 days ago1727348063
0xD8E3A701...26927af07
0 ETH
208343212024-09-26 10:54:2342 days ago1727348063
0xD8E3A701...26927af07
0 ETH
208343212024-09-26 10:54:2342 days ago1727348063
0xD8E3A701...26927af07
0 ETH
208104122024-09-23 2:50:4746 days ago1727059847
0xD8E3A701...26927af07
0 ETH
208104122024-09-23 2:50:4746 days ago1727059847
0xD8E3A701...26927af07
0 ETH
208104122024-09-23 2:50:4746 days ago1727059847
0xD8E3A701...26927af07
0 ETH
208104122024-09-23 2:50:4746 days ago1727059847
0xD8E3A701...26927af07
0 ETH
208104122024-09-23 2:50:4746 days ago1727059847
0xD8E3A701...26927af07
0 ETH
208104122024-09-23 2:50:4746 days ago1727059847
0xD8E3A701...26927af07
0 ETH
208103962024-09-23 2:47:3546 days ago1727059655
0xD8E3A701...26927af07
0 ETH
208103962024-09-23 2:47:3546 days ago1727059655
0xD8E3A701...26927af07
0 ETH
208103962024-09-23 2:47:3546 days ago1727059655
0xD8E3A701...26927af07
0 ETH
View All Internal Transactions
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
PoolController

Compiler Version
v0.6.12+commit.27d51765

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion, None license

Contract Source Code (Solidity)

/**
 *Submitted for verification at Etherscan.io on 2021-01-08
*/

// SPDX-License-Identifier: MIT

pragma solidity ^0.6.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);
}

/**
 * @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 in extcodesize, which returns 0 for contracts in
        // construction, since the code is only stored at the end of the
        // constructor execution.

        uint256 size;
        // solhint-disable-next-line no-inline-assembly
        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");

        // solhint-disable-next-line avoid-low-level-calls, avoid-call-value
        (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");
        return _functionCallWithValue(target, data, value, errorMessage);
    }

    function _functionCallWithValue(address target, bytes memory data, uint256 weiValue, string memory errorMessage) private returns (bytes memory) {
        require(isContract(target), "Address: call to non-contract");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = target.call{ value: weiValue }(data);
        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

                // solhint-disable-next-line no-inline-assembly
                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}


/**
 * @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 SafeMath for uint256;
    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'
        // solhint-disable-next-line max-line-length
        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).add(value);
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    function safeDecreaseAllowance(IERC20 token, address spender, uint256 value) internal {
        uint256 newAllowance = token.allowance(address(this), spender).sub(value, "SafeERC20: decreased allowance below zero");
        _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
            // solhint-disable-next-line max-line-length
            require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed");
        }
    }
}

pragma solidity ^0.6.0;

/**
 * @dev Wrappers over Solidity's arithmetic operations with added overflow
 * checks.
 *
 * Arithmetic operations in Solidity wrap on overflow. This can easily result
 * in bugs, because programmers usually assume that an overflow raises an
 * error, which is the standard behavior in high level programming languages.
 * `SafeMath` restores this intuition by reverting the transaction when an
 * operation overflows.
 *
 * Using this library instead of the unchecked operations eliminates an entire
 * class of bugs, so it's recommended to use it always.
 */
library SafeMath {
    /**
     * @dev Returns the addition of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `+` operator.
     *
     * Requirements:
     *
     * - Addition cannot overflow.
     */
    function add(uint256 a, uint256 b) internal pure returns (uint256) {
        uint256 c = a + b;
        require(c >= a, "SafeMath: addition overflow");

        return c;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting on
     * overflow (when the result is negative).
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(uint256 a, uint256 b) internal pure returns (uint256) {
        return sub(a, b, "SafeMath: subtraction overflow");
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting with custom message on
     * overflow (when the result is negative).
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        require(b <= a, errorMessage);
        uint256 c = a - b;

        return c;
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `*` operator.
     *
     * Requirements:
     *
     * - Multiplication cannot overflow.
     */
    function mul(uint256 a, uint256 b) internal pure returns (uint256) {
        // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
        // benefit is lost if 'b' is also tested.
        // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
        if (a == 0) {
            return 0;
        }

        uint256 c = a * b;
        require(c / a == b, "SafeMath: multiplication overflow");

        return c;
    }

    /**
     * @dev Returns the integer division of two unsigned integers. Reverts on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator. Note: this function uses a
     * `revert` opcode (which leaves remaining gas untouched) while Solidity
     * uses an invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b) internal pure returns (uint256) {
        return div(a, b, "SafeMath: division by zero");
    }

    /**
     * @dev Returns the integer division of two unsigned integers. Reverts with custom message on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator. Note: this function uses a
     * `revert` opcode (which leaves remaining gas untouched) while Solidity
     * uses an invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        require(b > 0, errorMessage);
        uint256 c = a / b;
        // assert(a == b * c + a % b); // There is no case in which this doesn't hold

        return c;
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * Reverts when dividing by zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b) internal pure returns (uint256) {
        return mod(a, b, "SafeMath: modulo by zero");
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * Reverts with custom message when dividing by zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        require(b != 0, errorMessage);
        return a % b;
    }
}

/*
 * @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 GSN 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 payable) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes memory) {
        this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
        return msg.data;
    }
}


/**
 * @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.
 */
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 () internal {
        address msgSender = _msgSender();
        _owner = msgSender;
        emit OwnershipTransferred(address(0), msgSender);
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view 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 {
        emit OwnershipTransferred(_owner, address(0));
        _owner = 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");
        emit OwnershipTransferred(_owner, newOwner);
        _owner = newOwner;
    }
}

/**
 * @dev Implementation of the {IERC20} interface.
 *
 * This implementation is agnostic to the way tokens are created. This means
 * that a supply mechanism has to be added in a derived contract using {_mint}.
 * For a generic mechanism see {ERC20PresetMinterPauser}.
 *
 * TIP: For a detailed writeup see our guide
 * https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How
 * to implement supply mechanisms].
 *
 * We have followed general OpenZeppelin guidelines: functions revert instead
 * of returning `false` on failure. This behavior is nonetheless conventional
 * and does not conflict with the expectations of ERC20 applications.
 *
 * Additionally, an {Approval} event is emitted on calls to {transferFrom}.
 * This allows applications to reconstruct the allowance for all accounts just
 * by listening to said events. Other implementations of the EIP may not emit
 * these events, as it isn't required by the specification.
 *
 * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}
 * functions have been added to mitigate the well-known issues around setting
 * allowances. See {IERC20-approve}.
 */
contract ERC20 is Context, IERC20 {
    using SafeMath for uint256;
    using Address for address;

    mapping (address => uint256) private _balances;

    mapping (address => mapping (address => uint256)) private _allowances;

    uint256 private _totalSupply;

    string private _name;
    string private _symbol;
    uint8 private _decimals;

    /**
     * @dev Sets the values for {name} and {symbol}, initializes {decimals} with
     * a default value of 18.
     *
     * To select a different value for {decimals}, use {_setupDecimals}.
     *
     * All three of these values are immutable: they can only be set once during
     * construction.
     */
    constructor (string memory name, string memory symbol) public {
        _name = name;
        _symbol = symbol;
        _decimals = 18;
    }

    /**
     * @dev Returns the name of the token.
     */
    function name() public view returns (string memory) {
        return _name;
    }

    /**
     * @dev Returns the symbol of the token, usually a shorter version of the
     * name.
     */
    function symbol() public view returns (string memory) {
        return _symbol;
    }

    /**
     * @dev Returns the number of decimals used to get its user representation.
     * For example, if `decimals` equals `2`, a balance of `505` tokens should
     * be displayed to a user as `5,05` (`505 / 10 ** 2`).
     *
     * Tokens usually opt for a value of 18, imitating the relationship between
     * Ether and Wei. This is the value {ERC20} uses, unless {_setupDecimals} is
     * called.
     *
     * NOTE: This information is only used for _display_ purposes: it in
     * no way affects any of the arithmetic of the contract, including
     * {IERC20-balanceOf} and {IERC20-transfer}.
     */
    function decimals() public view returns (uint8) {
        return _decimals;
    }

    /**
     * @dev See {IERC20-totalSupply}.
     */
    function totalSupply() public view override returns (uint256) {
        return _totalSupply;
    }

    /**
     * @dev See {IERC20-balanceOf}.
     */
    function balanceOf(address account) public view override returns (uint256) {
        return _balances[account];
    }

    /**
     * @dev See {IERC20-transfer}.
     *
     * Requirements:
     *
     * - `recipient` cannot be the zero address.
     * - the caller must have a balance of at least `amount`.
     */
    function transfer(address recipient, uint256 amount) public virtual override returns (bool) {
        _transfer(_msgSender(), recipient, amount);
        return true;
    }

    /**
     * @dev See {IERC20-allowance}.
     */
    function allowance(address owner, address spender) public view virtual override returns (uint256) {
        return _allowances[owner][spender];
    }

    /**
     * @dev See {IERC20-approve}.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function approve(address spender, uint256 amount) public virtual override returns (bool) {
        _approve(_msgSender(), spender, amount);
        return true;
    }

    /**
     * @dev See {IERC20-transferFrom}.
     *
     * Emits an {Approval} event indicating the updated allowance. This is not
     * required by the EIP. See the note at the beginning of {ERC20};
     *
     * Requirements:
     * - `sender` and `recipient` cannot be the zero address.
     * - `sender` must have a balance of at least `amount`.
     * - the caller must have allowance for ``sender``'s tokens of at least
     * `amount`.
     */
    function transferFrom(address sender, address recipient, uint256 amount) public virtual override returns (bool) {
        _transfer(sender, recipient, amount);
        _approve(sender, _msgSender(), _allowances[sender][_msgSender()].sub(amount, "ERC20: transfer amount exceeds allowance"));
        return true;
    }

    /**
     * @dev Atomically increases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) {
        _approve(_msgSender(), spender, _allowances[_msgSender()][spender].add(addedValue));
        return true;
    }

    /**
     * @dev Atomically decreases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     * - `spender` must have allowance for the caller of at least
     * `subtractedValue`.
     */
    function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) {
        _approve(_msgSender(), spender, _allowances[_msgSender()][spender].sub(subtractedValue, "ERC20: decreased allowance below zero"));
        return true;
    }

    /**
     * @dev Moves tokens `amount` from `sender` to `recipient`.
     *
     * This is internal function is equivalent to {transfer}, and can be used to
     * e.g. implement automatic token fees, slashing mechanisms, etc.
     *
     * Emits a {Transfer} event.
     *
     * Requirements:
     *
     * - `sender` cannot be the zero address.
     * - `recipient` cannot be the zero address.
     * - `sender` must have a balance of at least `amount`.
     */
    function _transfer(address sender, address recipient, uint256 amount) internal virtual {
        require(sender != address(0), "ERC20: transfer from the zero address");
        require(recipient != address(0), "ERC20: transfer to the zero address");

        _beforeTokenTransfer(sender, recipient, amount);

        _balances[sender] = _balances[sender].sub(amount, "ERC20: transfer amount exceeds balance");
        _balances[recipient] = _balances[recipient].add(amount);
        emit Transfer(sender, recipient, amount);
    }

    /** @dev Creates `amount` tokens and assigns them to `account`, increasing
     * the total supply.
     *
     * Emits a {Transfer} event with `from` set to the zero address.
     *
     * Requirements
     *
     * - `to` cannot be the zero address.
     */
    function _mint(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: mint to the zero address");

        _beforeTokenTransfer(address(0), account, amount);

        _totalSupply = _totalSupply.add(amount);
        _balances[account] = _balances[account].add(amount);
        emit Transfer(address(0), account, amount);
    }

    /**
     * @dev Destroys `amount` tokens from `account`, reducing the
     * total supply.
     *
     * Emits a {Transfer} event with `to` set to the zero address.
     *
     * Requirements
     *
     * - `account` cannot be the zero address.
     * - `account` must have at least `amount` tokens.
     */
    function _burn(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: burn from the zero address");

        _beforeTokenTransfer(account, address(0), amount);

        _balances[account] = _balances[account].sub(amount, "ERC20: burn amount exceeds balance");
        _totalSupply = _totalSupply.sub(amount);
        emit Transfer(account, address(0), amount);
    }

    /**
     * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens.
     *
     * This internal function is equivalent to `approve`, and can be used to
     * e.g. set automatic allowances for certain subsystems, etc.
     *
     * Emits an {Approval} event.
     *
     * Requirements:
     *
     * - `owner` cannot be the zero address.
     * - `spender` cannot be the zero address.
     */
    function _approve(address owner, address spender, uint256 amount) internal virtual {
        require(owner != address(0), "ERC20: approve from the zero address");
        require(spender != address(0), "ERC20: approve to the zero address");

        _allowances[owner][spender] = amount;
        emit Approval(owner, spender, amount);
    }

    /**
     * @dev Sets {decimals} to a value other than the default one of 18.
     *
     * WARNING: This function should only be called from the constructor. Most
     * applications that interact with token contracts will not expect
     * {decimals} to ever change, and may work incorrectly if it does.
     */
    function _setupDecimals(uint8 decimals_) internal {
        _decimals = decimals_;
    }

    /**
     * @dev Hook that is called before any transfer of tokens. This includes
     * minting and burning.
     *
     * Calling conditions:
     *
     * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens
     * will be to transferred to `to`.
     * - when `from` is zero, `amount` tokens will be minted for `to`.
     * - when `to` is zero, `amount` of ``from``'s tokens will be burned.
     * - `from` and `to` are never both zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(address from, address to, uint256 amount) internal virtual { }
}


/**
 * @dev Extension of {ERC20} that allows token holders to destroy both their own
 * tokens and those that they have an allowance for, in a way that can be
 * recognized off-chain (via event analysis).
 */
abstract contract ERC20Burnable is Context, ERC20 {
    /**
     * @dev Destroys `amount` tokens from the caller.
     *
     * See {ERC20-_burn}.
     */
    function burn(uint256 amount) public virtual {
        _burn(_msgSender(), amount);
    }

    /**
     * @dev Destroys `amount` tokens from `account`, deducting from the caller's
     * allowance.
     *
     * See {ERC20-_burn} and {ERC20-allowance}.
     *
     * Requirements:
     *
     * - the caller must have allowance for ``accounts``'s tokens of at least
     * `amount`.
     */
    function burnFrom(address account, uint256 amount) public virtual {
        uint256 decreasedAllowance = allowance(account, _msgSender()).sub(amount, "ERC20: burn amount exceeds allowance");

        _approve(account, _msgSender(), decreasedAllowance);
        _burn(account, amount);
    }
}


contract DuckToken is ERC20Burnable, Ownable {

    uint public constant PRESALE_SUPPLY         = 20000000e18;
    uint public constant TEAM_SUPPLY            = 10000000e18;
    uint public constant MAX_FARMING_POOL       = 70000000e18;

    uint public currentFarmingPool;

    constructor(address presaleWallet, address teamWallet) public ERC20("DuckToken", "DLC") {
        _mint(presaleWallet, PRESALE_SUPPLY);
        _mint(teamWallet, TEAM_SUPPLY);
    }

    function mint(address to, uint256 amount) public onlyOwner {
        require(currentFarmingPool.add(amount) <= MAX_FARMING_POOL, "exceed farming amount");
        currentFarmingPool += amount; 
        _mint(to, amount);
  }
}

contract PoolController is Ownable {
    
    // DUCK TOKEN
    DuckToken public duck;
    // Array of pools
    Pool[] public pools;
    
    address public devAddress;
//   address ddimAddress = 0xFbEEa1C75E4c4465CB2FCCc9c6d6afe984558E20;
    address public ddimTokenAddress;
    address public drainAddress;

    // Mapping is address is pool
    mapping(address => bool) public canMint;

    event NewPool(address indexed poolAddress, address lpToken);

    constructor(address _duckTokenAddress, address _devAddress, address _ddimTokenAddress, address _drainAddress) public {
        duck = DuckToken(_duckTokenAddress);
        devAddress = _devAddress;
        ddimTokenAddress = _ddimTokenAddress;
        drainAddress = _drainAddress;
    }

    function setDrainAddress(address _drainAddress) public onlyOwner {
        drainAddress = _drainAddress;
    }
    
    // Add a new pool. Can only be called by the owner.
    function newPool(address lpToken, uint startingBlock, uint[] memory blocks, uint[] memory farmingSupplies) public onlyOwner {
        Pool pool = new Pool(lpToken, startingBlock, blocks, farmingSupplies);
        pools.push(pool);

        canMint[address(pool)] = true;
        emit NewPool(address(pool), lpToken);
    }

    // Update already created pool by adding NEW period. Can only be called by the owner.
    function addPeriod(uint poolIndex, uint startingBlock, uint blocks, uint farmingSupply) public onlyOwner {
        pools[poolIndex].addPeriod(startingBlock, blocks, farmingSupply);
    }
    
    // Add new revenue for a pool. Can only be called by the owner. 
    function addRevenue(uint poolIndex, address tokenAddress, uint amount, address _revenueSource) public onlyOwner {
        pools[poolIndex].addRevenue(tokenAddress, amount, _revenueSource);
    }

    function changeEmergencyWithdrawStatus(uint poolIndex, bool status) public onlyOwner {
        pools[poolIndex].changeEmergencyWithdrawStatus(status);
    }

    // Mint DUCK TOKEN. Can be called by pools only
    function mint(address to, uint value) public {
        require(canMint[msg.sender], "only pools");
        duck.transferFrom(drainAddress, to, value);
    }
}

abstract contract IUniswapPool {
  address public token0;
  address public token1;
}

abstract contract IUniswapRouter {
  function removeLiquidity(
        address tokenA,
        address tokenB,
        uint liquidity,
        uint amountAMin,
        uint amountBMin,
        address to,
        uint deadline
    ) virtual external returns (uint amountA, uint amountB);
}

contract Pool {

  using SafeMath for uint256;
  using SafeERC20 for IERC20;

    // Info of each user.
  struct UserInfo {
    uint256 amount;     // How many LP tokens the user has provided.
    uint256 rewardDebt; // Reward debt. See explanation below.
    //
    // We do some fancy math here. Basically, any point in time, the amount of SUSHIs
    // entitled to a user but is pending to be distributed is:
    //
    //   pending reward = (user.amount * pool.accSushiPerShare) - user.rewardDebt
    //
    // Whenever a user deposits or withdraws LP tokens to a pool. Here's what happens:
    //   1. The pool's `accSushiPerShare` (and `lastRewardBlock`) gets updated.
    //   2. User receives the pending reward sent to his/her address.
    //   3. User's `amount` gets updated.
    //   4. User's `rewardDebt` gets updated.
  }

  // Info of each period.
    struct Period {
        uint startingBlock;
        uint blocks;
        uint farmingSupply;
        uint tokensPerBlock;
    }

  // Info of each period.
    Period[] public periods;

  // Controller address
    PoolController public controller;

  // Last block number that DUCKs distribution occurs.
    uint public lastRewardBlock;
  // The DUCK TOKEN
  ERC20Burnable public duck;
  // Address of LP token contract.
  IERC20 public lpToken;
  // Accumulated DUCKs per share, times 1e18. See below.
  uint public accDuckPerShare;

  // Info of each user that stakes LP tokens.
  mapping(address => UserInfo) public userInfo;
  
  IUniswapRouter public uniswapRouter = IUniswapRouter(0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D);

  //Revenue part
  struct Revenue {
    address tokenAddress;
    uint totalSupply;
    uint amount;
  }
    
  // Array of created revenues
  Revenue[] public revenues;
  
  // mapping of claimed user revenues
  mapping(address => mapping(uint => bool)) revenuesClaimed;

  bool public canEmergencyWithdraw;

  event Deposit(address indexed from, uint amount);
  event Withdraw(address indexed to, uint amount);
  event NewPeriod(uint indexed startingBlock, uint indexed blocks, uint farmingSupply);
  event EmergencyWithdraw(address indexed user, uint256 indexed pid, uint256 amount);

    modifier onlyController() {
        require(msg.sender == address(controller), "onlyController"); 
        _;
    }
    
    constructor(address _lpToken, uint _startingBlock, uint[] memory _blocks, uint[] memory _farmingSupplies) public {
    require(_blocks.length > 0, "emply data");
    require(_blocks.length == _farmingSupplies.length, "invalid data");

    controller = PoolController(msg.sender);
    duck = ERC20Burnable(controller.duck());
    lpToken = IERC20(_lpToken);

    addPeriod(_startingBlock, _blocks[0], _farmingSupplies[0]);
    uint _bufStartingBlock = _startingBlock.add(_blocks[0]);

    for(uint i = 1; i < _blocks.length; i++) {
        addPeriod(_bufStartingBlock, _blocks[i], _farmingSupplies[i]);
        _bufStartingBlock = _bufStartingBlock.add(_blocks[i]);
    }
    
    IERC20(_lpToken).approve(address(uniswapRouter), uint256(-1));
    
    lastRewardBlock = _startingBlock;
    }
    
  // Update a pool by adding NEW period. Can only be called by the controller.
    function addPeriod(uint startingBlock, uint blocks, uint farmingSupply) public onlyController {
    require(startingBlock >= block.number, "startingBlock should be greater than now");
    
    if(periods.length > 0) {
      require(startingBlock > periods[periods.length-1].startingBlock.add(periods[periods.length-1].blocks), "two periods in the same time");
    }

        uint tokensPerBlock = farmingSupply.div(blocks);
        Period memory newPeriod = Period({
            startingBlock: startingBlock,
            blocks: blocks.sub(1),
            farmingSupply: farmingSupply,
            tokensPerBlock: tokensPerBlock
        });

        periods.push(newPeriod);
    emit NewPeriod(startingBlock, blocks, farmingSupply);
    }

  // Update reward variables of the given pool to be up-to-date.
  function updatePool() public {
    if (block.number <= lastRewardBlock) {
      return;
    }

    claimRevenue(msg.sender);
 
    uint256 lpSupply = lpToken.balanceOf(address(this));
    if (lpSupply == 0) {
      lastRewardBlock = block.number;
      return;
    }
 
    uint256 duckReward = calculateDuckTokensForMint();
    if (duckReward > 0) {
      controller.mint(controller.devAddress(), duckReward.mul(7).div(100));
      controller.mint(address(this), duckReward.mul(93).div(100));
 
      accDuckPerShare = accDuckPerShare.add(duckReward.mul(1e18).mul(93).div(100).div(lpSupply));
    }
    
    lastRewardBlock = block.number;
  }
  
  // Deposit LP tokens to Pool for DUCK allocation.
  function deposit(uint256 amount) public {
    require(amount > 0, "amount must be more than zero");
    UserInfo storage user = userInfo[msg.sender];
 
    updatePool();
 
    if (user.amount > 0) {
      uint256 pending = user.amount.mul(accDuckPerShare).div(1e18).sub(user.rewardDebt);
      if(pending > 0) {
        safeDuckTransfer(msg.sender, pending);
      }
    }
    
    user.amount = user.amount.add(amount);
    lpToken.safeTransferFrom(msg.sender, address(this), amount);
    
    user.rewardDebt = user.amount.mul(accDuckPerShare).div(1e18);
    
    emit Deposit(msg.sender, amount);
  }

   // Withdraw LP tokens from the Pool.
  function withdraw(uint256 amount) public {

    UserInfo storage user = userInfo[msg.sender];
    
    require(user.amount >= amount, "withdraw: not good");

    updatePool();
    
    uint256 pending = user.amount.mul(accDuckPerShare).div(1e18).sub(user.rewardDebt);
    if(pending > 0) {
      safeDuckTransfer(msg.sender, pending);
    }
    
    if(amount > 0) {
      // lpToken.safeTransfer(address(msg.sender), amount);
      user.amount = user.amount.sub(amount);

      uniWithdraw(msg.sender, amount);
    }
     
    user.rewardDebt = user.amount.mul(accDuckPerShare).div(1e18);
    emit Withdraw(msg.sender, amount);
  }
  
  // Withdraw without caring about rewards. EMERGENCY ONLY.
    function emergencyWithdraw(uint256 pid) public {
    require(canEmergencyWithdraw, "function disabled");
    
        UserInfo storage user = userInfo[msg.sender];
        lpToken.safeTransfer(address(msg.sender), user.amount);
        emit EmergencyWithdraw(msg.sender, pid, user.amount);
        user.amount = 0;
        user.rewardDebt = 0;
    }

  function changeEmergencyWithdrawStatus(bool status) public onlyController {
    canEmergencyWithdraw = status;
  }

  function uniWithdraw(address receiver, uint lpTokenAmount) internal {
    IUniswapPool uniswapPool = IUniswapPool(address(lpToken));

    address token0 = uniswapPool.token0();
    address token1 = uniswapPool.token1();

    (uint amountA, uint amountB) = uniswapRouter.removeLiquidity(token0, token1, lpTokenAmount, 1, 1, address(this), block.timestamp + 100);

    bool isDuckBurned;
    bool token0Sent;
    bool token1Sent;
    if(token0 == address(duck)) {
        duck.burn(amountA);
        isDuckBurned = true;
        token0Sent = true;
    }

    if(token1 == address(duck)) {
        duck.burn(amountB);
        isDuckBurned = true;
        token1Sent = true;
    }
    
    if(!token0Sent) {
        if(token0 == controller.ddimTokenAddress() && !isDuckBurned) {
            IERC20(controller.ddimTokenAddress()).transfer(address(0), amountA);
        } else {
            IERC20(token0).transfer(receiver, amountA);
        }
    }
    
    if(!token1Sent) {
        if(token1 == controller.ddimTokenAddress() && !isDuckBurned) {
            IERC20(controller.ddimTokenAddress()).transfer(address(0), amountB);
        } else {
            IERC20(token1).transfer(receiver, amountB);
        }
    }
  }

  // Get user pending reward. Frontend function..
  function getUserPendingReward(address userAddress) public view returns(uint) {
    UserInfo storage user = userInfo[userAddress];
    uint256 duckReward = calculateDuckTokensForMint();
    
    uint256 lpSupply = lpToken.balanceOf(address(this));
    if (lpSupply == 0) {
      return 0;
    }
    
    uint _accDuckPerShare = accDuckPerShare.add(duckReward.mul(1e18).mul(93).div(100).div(lpSupply));

    return user.amount.mul(_accDuckPerShare).div(1e18).sub(user.rewardDebt);
  }

  // Get current period index.
  function getCurrentPeriodIndex() public view returns(uint) {
    for(uint i = 0; i < periods.length; i++) {
        if(block.number > periods[i].startingBlock && block.number < periods[i].startingBlock.add(periods[i].blocks)) {
            return i;
        }
    }
  }

  // Calculate DUCK Tokens for mint near current time.
  function calculateDuckTokensForMint() public view returns(uint) {
    uint totalTokens;
    bool overflown;

    for(uint i = 0; i < periods.length; i++) {
        if(block.number < periods[i].startingBlock) {
            break;
        }

        uint buf = periods[i].startingBlock.add(periods[i].blocks);

      if(lastRewardBlock > buf) {
        continue;
      }

        if(block.number > buf) {
              totalTokens += buf.sub(max(lastRewardBlock, periods[i].startingBlock-1)).mul(periods[i].tokensPerBlock);
            overflown = true;
        } else {
            if(overflown) {
                totalTokens += block.number.sub(periods[i].startingBlock-1).mul(periods[i].tokensPerBlock);
            } else {
          totalTokens += block.number.sub(max(lastRewardBlock, periods[i].startingBlock-1)).mul(periods[i].tokensPerBlock);
            }

            break;
        }
    }

    return totalTokens;
  }

  // Safe duck transfer function, just in case if rounding error causes pool to not have enough DUCKs.
  function safeDuckTransfer(address to, uint256 amount) internal {
    uint256 duckBal = duck.balanceOf(address(this));
    if (amount > duckBal) {
      duck.transfer(to, duckBal);
    } else {
      duck.transfer(to, amount);
    }
  }
    
  //--------------------------------------------------------------------------------------
  //---------------------------------REVENUE PART-----------------------------------------
  //--------------------------------------------------------------------------------------
  
  // Add new Revenue, can be called only by controller
  function addRevenue(address _tokenAddress, uint _amount, address _revenueSource) public onlyController {
    require(revenues.length < 50, "exceed revenue limit");

    uint revenueBefore = IERC20(_tokenAddress).balanceOf(address(this));
    IERC20(_tokenAddress).transferFrom(_revenueSource, address(this), _amount);
    uint revenueAfter = IERC20(_tokenAddress).balanceOf(address(this));
    _amount = revenueAfter.sub(revenueBefore);

    Revenue memory revenue = Revenue({
      tokenAddress: _tokenAddress,
      totalSupply: lpToken.balanceOf(address(this)),
      amount: _amount
    });

    revenues.push(revenue);
  }

  // Get user last revenue. Frontend function.
  function getUserLastRevenue(address userAddress) public view returns(address, uint) {
    UserInfo storage user = userInfo[userAddress];

    for(uint i = 0; i < revenues.length; i++) {
      if(!revenuesClaimed[userAddress][i]) {
        uint userRevenue = revenues[i].amount.mul(user.amount).div(revenues[i].totalSupply);
        return (revenues[i].tokenAddress, userRevenue);
      }
    }
  }
    
  // claimRevenue is private function, called on updatePool for transaction caller
  function claimRevenue(address userAddress) private {
    UserInfo storage user = userInfo[userAddress];

    for(uint i = 0; i < revenues.length; i++) {
      if(!revenuesClaimed[userAddress][i]) {
        revenuesClaimed[userAddress][i] = true;
        uint userRevenue = revenues[i].amount.mul(user.amount).div(revenues[i].totalSupply);

        safeRevenueTransfer(revenues[i].tokenAddress, userAddress, userRevenue);
      }
    }
  }
    
  // Safe revenue transfer for avoid misscalculations
  function safeRevenueTransfer(address tokenAddress, address to, uint amount) private {
    uint balance = IERC20(tokenAddress).balanceOf(address(this));
    if(balance == 0 || amount == 0) {
      return;
    }

    if(balance >= amount) {
      IERC20(tokenAddress).transfer(to, amount);
    } else {
      IERC20(tokenAddress).transfer(to, balance);
    }
  }

  function max(uint a, uint b) public pure returns(uint) {
    if(a > b) {
      return a;
    }
    return b;
  }
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"_duckTokenAddress","type":"address"},{"internalType":"address","name":"_devAddress","type":"address"},{"internalType":"address","name":"_ddimTokenAddress","type":"address"},{"internalType":"address","name":"_drainAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"poolAddress","type":"address"},{"indexed":false,"internalType":"address","name":"lpToken","type":"address"}],"name":"NewPool","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"},{"inputs":[{"internalType":"uint256","name":"poolIndex","type":"uint256"},{"internalType":"uint256","name":"startingBlock","type":"uint256"},{"internalType":"uint256","name":"blocks","type":"uint256"},{"internalType":"uint256","name":"farmingSupply","type":"uint256"}],"name":"addPeriod","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"poolIndex","type":"uint256"},{"internalType":"address","name":"tokenAddress","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"address","name":"_revenueSource","type":"address"}],"name":"addRevenue","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"canMint","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"poolIndex","type":"uint256"},{"internalType":"bool","name":"status","type":"bool"}],"name":"changeEmergencyWithdrawStatus","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"ddimTokenAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"devAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"drainAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"duck","outputs":[{"internalType":"contract DuckToken","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"lpToken","type":"address"},{"internalType":"uint256","name":"startingBlock","type":"uint256"},{"internalType":"uint256[]","name":"blocks","type":"uint256[]"},{"internalType":"uint256[]","name":"farmingSupplies","type":"uint256[]"}],"name":"newPool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"pools","outputs":[{"internalType":"contract Pool","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_drainAddress","type":"address"}],"name":"setDrainAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}]

608060405234801561001057600080fd5b50604051613d15380380613d158339818101604052608081101561003357600080fd5b508051602082015160408301516060909301519192909160006100546100f1565b600080546001600160a01b0319166001600160a01b0383169081178255604051929350917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a350600180546001600160a01b039586166001600160a01b03199182161790915560038054948616948216949094179093556004805492851692841692909217909155600580549190931691161790556100f5565b3390565b613c11806101046000396000f3fe60806040523480156200001157600080fd5b50600436106200010c5760003560e01c806395899a8311620000a5578063b6c38432116200006f578063b6c38432146200038e578063c2ba474414620003b7578063d5226a1c14620003f4578063f2fde38b14620003fe576200010c565b806395899a8314620001b8578063970d20e914620001ea578063ac4afa381462000229578063ad3448771462000249576200010c565b80635c20cfe811620000e75780635c20cfe81462000172578063715018a6146200019a5780638da5cb5b14620001a457806392f2cff014620001ae576200010c565b80633ad10ef6146200011157806340c10f191462000137578063526003441462000168575b600080fd5b6200011b62000427565b604080516001600160a01b039092168252519081900360200190f35b62000166600480360360408110156200014f57600080fd5b506001600160a01b03813516906020013562000436565b005b6200011b6200051c565b62000166600480360360408110156200018a57600080fd5b508035906020013515156200052b565b6200016662000603565b6200011b620006a9565b6200011b620006b8565b6200016660048036036080811015620001d057600080fd5b5080359060208101359060408101359060600135620006c7565b62000166600480360360808110156200020257600080fd5b508035906001600160a01b03602082013581169160408101359160609091013516620007ae565b6200011b600480360360208110156200024157600080fd5b50356200087a565b62000166600480360360808110156200026157600080fd5b6001600160a01b03823516916020810135918101906060810160408201356401000000008111156200029257600080fd5b820183602082011115620002a557600080fd5b80359060200191846020830284011164010000000083111715620002c857600080fd5b91908080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525092959493602081019350359150506401000000008111156200031957600080fd5b8201836020820111156200032c57600080fd5b803590602001918460208302840111640100000000831117156200034f57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550620008a2945050505050565b6200016660048036036020811015620003a657600080fd5b50356001600160a01b031662000a7f565b620003e060048036036020811015620003cf57600080fd5b50356001600160a01b031662000afd565b604080519115158252519081900360200190f35b6200011b62000b12565b62000166600480360360208110156200041657600080fd5b50356001600160a01b031662000b21565b6003546001600160a01b031681565b3360009081526006602052604090205460ff1662000488576040805162461bcd60e51b815260206004820152600a6024820152696f6e6c7920706f6f6c7360b01b604482015290519081900360640190fd5b600154600554604080516323b872dd60e01b81526001600160a01b039283166004820152858316602482015260448101859052905191909216916323b872dd9160648083019260209291908290030181600087803b158015620004ea57600080fd5b505af1158015620004ff573d6000803e3d6000fd5b505050506040513d60208110156200051657600080fd5b50505050565b6004546001600160a01b031681565b6200053562000c1f565b6000546001600160a01b0390811691161462000587576040805162461bcd60e51b8152602060048201819052602482015260008051602062003bbc833981519152604482015290519081900360640190fd5b600282815481106200059557fe5b60009182526020822001546040805163500d235760e11b8152841515600482015290516001600160a01b039092169263a01a46ae9260248084019382900301818387803b158015620005e657600080fd5b505af1158015620005fb573d6000803e3d6000fd5b505050505050565b6200060d62000c1f565b6000546001600160a01b039081169116146200065f576040805162461bcd60e51b8152602060048201819052602482015260008051602062003bbc833981519152604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b6000546001600160a01b031690565b6005546001600160a01b031681565b620006d162000c1f565b6000546001600160a01b0390811691161462000723576040805162461bcd60e51b8152602060048201819052602482015260008051602062003bbc833981519152604482015290519081900360640190fd5b600284815481106200073157fe5b600091825260208220015460408051633be64ed760e01b815260048101879052602481018690526044810185905290516001600160a01b0390921692633be64ed79260648084019382900301818387803b1580156200078f57600080fd5b505af1158015620007a4573d6000803e3d6000fd5b5050505050505050565b620007b862000c1f565b6000546001600160a01b039081169116146200080a576040805162461bcd60e51b8152602060048201819052602482015260008051602062003bbc833981519152604482015290519081900360640190fd5b600284815481106200081857fe5b6000918252602082200154604080516317949d5f60e21b81526001600160a01b03878116600483015260248201879052858116604483015291519190921692635e52757c926064808201939182900301818387803b1580156200078f57600080fd5b600281815481106200088857fe5b6000918252602090912001546001600160a01b0316905081565b620008ac62000c1f565b6000546001600160a01b03908116911614620008fe576040805162461bcd60e51b8152602060048201819052602482015260008051602062003bbc833981519152604482015290519081900360640190fd5b600084848484604051620009129062000c23565b80856001600160a01b031681526020018481526020018060200180602001838103835285818151815260200191508051906020019060200280838360005b838110156200096a57818101518382015260200162000950565b50505050905001838103825284818151815260200191508051906020019060200280838360005b83811015620009ab57818101518382015260200162000991565b505050509050019650505050505050604051809103906000f080158015620009d7573d6000803e3d6000fd5b506002805460018082019092557f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace0180546001600160a01b0319166001600160a01b03848116918217909255600081815260066020908152604091829020805460ff19169095179094558051928a16835251939450927f77948cb83ef3caff9ac13dfab1ea1f8a6875c98370287ce587f5dbc74cc5b6b0929181900390910190a25050505050565b62000a8962000c1f565b6000546001600160a01b0390811691161462000adb576040805162461bcd60e51b8152602060048201819052602482015260008051602062003bbc833981519152604482015290519081900360640190fd5b600580546001600160a01b0319166001600160a01b0392909216919091179055565b60066020526000908152604090205460ff1681565b6001546001600160a01b031681565b62000b2b62000c1f565b6000546001600160a01b0390811691161462000b7d576040805162461bcd60e51b8152602060048201819052602482015260008051602062003bbc833981519152604482015290519081900360640190fd5b6001600160a01b03811662000bc45760405162461bcd60e51b815260040180806020018281038252602681526020018062003b966026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b3390565b612f648062000c328339019056fe6080604052600780546001600160a01b031916737a250d5630b4cf539739df2c5dacb4c659f2488d1790553480156200003757600080fd5b5060405162002f6438038062002f64833981810160405260808110156200005d57600080fd5b815160208301516040808501805191519395929483019291846401000000008211156200008957600080fd5b9083019060208201858111156200009f57600080fd5b8251866020820283011164010000000082111715620000bd57600080fd5b82525081516020918201928201910280838360005b83811015620000ec578181015183820152602001620000d2565b50505050905001604052602001805160405193929190846401000000008211156200011657600080fd5b9083019060208201858111156200012c57600080fd5b82518660208202830111640100000000821117156200014a57600080fd5b82525081516020918201928201910280838360005b83811015620001795781810151838201526020016200015f565b505050509050016040525050506000825111620001ca576040805162461bcd60e51b815260206004820152600a602482015269656d706c79206461746160b01b604482015290519081900360640190fd5b805182511462000210576040805162461bcd60e51b815260206004820152600c60248201526b696e76616c6964206461746160a01b604482015290519081900360640190fd5b600180546001600160a01b031916331790819055604080516335489a8760e21b815290516001600160a01b03929092169163d5226a1c91600480820192602092909190829003018186803b1580156200026857600080fd5b505afa1580156200027d573d6000803e3d6000fd5b505050506040513d60208110156200029457600080fd5b5051600380546001600160a01b03199081166001600160a01b0393841617909155600480549091169186169190911790558151620003049084908490600090620002da57fe5b602002602001015183600081518110620002f057fe5b60200260200101516200043c60201b60201c565b600062000335836000815181106200031857fe5b602002602001015185620006e960201b620014f91790919060201c565b905060015b8351811015620003a4576200036b828583815181106200035657fe5b6020026020010151858481518110620002f057fe5b620003998482815181106200037c57fe5b602002602001015183620006e960201b620014f91790919060201c565b91506001016200033a565b506007546040805163095ea7b360e01b81526001600160a01b039283166004820152600019602482015290519187169163095ea7b3916044808201926020929091908290030181600087803b158015620003fd57600080fd5b505af115801562000412573d6000803e3d6000fd5b505050506040513d60208110156200042957600080fd5b505050600292909255506200090b915050565b6001546001600160a01b031633146200048d576040805162461bcd60e51b815260206004820152600e60248201526d37b7363ca1b7b73a3937b63632b960911b604482015290519081900360640190fd5b43831015620004ce5760405162461bcd60e51b815260040180806020018281038252602881526020018062002f3c6028913960400191505060405180910390fd5b600054156200059257600080546200053e91906000198101908110620004f057fe5b9060005260206000209060040201600101546000600160008054905003815481106200051857fe5b906000526020600020906004020160000154620006e960201b620014f91790919060201c565b831162000592576040805162461bcd60e51b815260206004820152601c60248201527f74776f20706572696f647320696e207468652073616d652074696d6500000000604482015290519081900360640190fd5b6000620005ae83836200074b60201b6200155a1790919060201c565b9050620005ba620008e3565b6040518060800160405280868152602001620005e66001876200079560201b6200159c1790919060201c565b8152602080820186905260409182018590526000805460018101825590805283517f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e563600490920291820155838201517f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e564820155838301517f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e56582015560608401517f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e5669091015581518681529151929350869288927f2c1ba73d1c003cfaa21fc5841652471b22221e83b5b01a9f7dc54de46e8ed64392908290030190a35050505050565b60008282018381101562000744576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b9392505050565b60006200074483836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250620007df60201b60201c565b60006200074483836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506200088660201b60201c565b600081836200086f5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156200083357818101518382015260200162000819565b50505050905090810190601f168015620008615780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816200087c57fe5b0495945050505050565b60008184841115620008db5760405162461bcd60e51b81526020600482018181528351602484015283519092839260449091019190850190808383600083156200083357818101518382015260200162000819565b505050900390565b6040518060800160405280600081526020016000815260200160008152602001600081525090565b612621806200091b6000396000f3fe608060405234801561001057600080fd5b50600436106101425760003560e01c8063a9f8d181116100b8578063d5226a1c1161007c578063d5226a1c14610361578063d95894d814610369578063da62fc28146103ae578063e3161ddd146103b6578063ea4a1104146103be578063f77c47911461040157610142565b8063a9f8d181146102f2578063b4f5a21a146102fa578063b6b55f2514610302578063c67106291461031f578063cb9a8c7e1461034557610142565b80635fcbd2851161010a5780635fcbd28514610221578063614ad28a146102455780636d5433e61461028e578063735de9f7146102c35780639f331649146102cb578063a01a46ae146102d357610142565b80631959a002146101475780632e1a7d4d146101865780633be64ed7146101a55780635312ea8e146101ce5780635e52757c146101eb575b600080fd5b61016d6004803603602081101561015d57600080fd5b50356001600160a01b0316610409565b6040805192835260208301919091528051918290030190f35b6101a36004803603602081101561019c57600080fd5b5035610422565b005b6101a3600480360360608110156101bb57600080fd5b508035906020810135906040013561054b565b6101a3600480360360208110156101e457600080fd5b50356107c0565b6101a36004803603606081101561020157600080fd5b506001600160a01b0381358116916020810135916040909101351661087a565b610229610bf0565b604080516001600160a01b039092168252519081900360200190f35b61026b6004803603602081101561025b57600080fd5b50356001600160a01b0316610bff565b604080516001600160a01b03909316835260208301919091528051918290030190f35b6102b1600480360360408110156102a457600080fd5b5080359060200135610cee565b60408051918252519081900360200190f35b610229610d08565b6102b1610d17565b6101a3600480360360208110156102e957600080fd5b50351515610ecd565b6102b1610f30565b6102b1610f36565b6101a36004803603602081101561031857600080fd5b5035610fb6565b6102b16004803603602081101561033557600080fd5b50356001600160a01b03166110ed565b61034d611204565b604080519115158252519081900360200190f35b61022961120d565b6103866004803603602081101561037f57600080fd5b503561121c565b604080516001600160a01b039094168452602084019290925282820152519081900360600190f35b6102b1611256565b6101a361125c565b6103db600480360360208110156103d457600080fd5b50356114b3565b604080519485526020850193909352838301919091526060830152519081900360800190f35b6102296114ea565b6006602052600090815260409020805460019091015482565b336000908152600660205260409020805482111561047c576040805162461bcd60e51b81526020600482015260126024820152711dda5d1a191c985dce881b9bdd0819dbdbd960721b604482015290519081900360640190fd5b61048461125c565b60006104bf82600101546104b9670de0b6b3a76400006104b360055487600001546115de90919063ffffffff16565b9061155a565b9061159c565b905080156104d1576104d13382611637565b82156104ef5781546104e3908461159c565b82556104ef33846117c8565b600554825461050b91670de0b6b3a7640000916104b3916115de565b600183015560408051848152905133917f884edad9ce6fa2440d8a54cc123490eb96d2768479d49ff9c7366125a9424364919081900360200190a2505050565b6001546001600160a01b0316331461059b576040805162461bcd60e51b815260206004820152600e60248201526d37b7363ca1b7b73a3937b63632b960911b604482015290519081900360640190fd5b438310156105da5760405162461bcd60e51b81526004018080602001828103825260288152602001806125796028913960400191505060405180910390fd5b6000541561068a5760008054610637919060001981019081106105f957fe5b90600052602060002090600402016001015460006001600080549050038154811061062057fe5b6000918252602090912060049091020154906114f9565b831161068a576040805162461bcd60e51b815260206004820152601c60248201527f74776f20706572696f647320696e207468652073616d652074696d6500000000604482015290519081900360640190fd5b6000610696828461155a565b90506106a0612526565b6040805160808101909152858152602081016106bd86600161159c565b8152602080820186905260409182018590526000805460018101825590805283517f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e563600490920291820155838201517f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e564820155838301517f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e56582015560608401517f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e5669091015581518681529151929350869288927f2c1ba73d1c003cfaa21fc5841652471b22221e83b5b01a9f7dc54de46e8ed64392908290030190a35050505050565b600a5460ff1661080b576040805162461bcd60e51b8152602060048201526011602482015270199d5b98dd1a5bdb88191a5cd8589b1959607a1b604482015290519081900360640190fd5b33600081815260066020526040902080546004549192610834926001600160a01b031691611ec4565b80546040805191825251839133917fbb757047c2b5f3974fe26b7c10f732e7bce710b0952a71082702781e62ae05959181900360200190a3600080825560019091015550565b6001546001600160a01b031633146108ca576040805162461bcd60e51b815260206004820152600e60248201526d37b7363ca1b7b73a3937b63632b960911b604482015290519081900360640190fd5b600854603211610918576040805162461bcd60e51b8152602060048201526014602482015273195e18d95959081c995d995b9d59481b1a5b5a5d60621b604482015290519081900360640190fd5b6000836001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b15801561096757600080fd5b505afa15801561097b573d6000803e3d6000fd5b505050506040513d602081101561099157600080fd5b5051604080516323b872dd60e01b81526001600160a01b038581166004830152306024830152604482018790529151929350908616916323b872dd916064808201926020929091908290030181600087803b1580156109ef57600080fd5b505af1158015610a03573d6000803e3d6000fd5b505050506040513d6020811015610a1957600080fd5b5050604080516370a0823160e01b815230600482015290516000916001600160a01b038716916370a0823191602480820192602092909190829003018186803b158015610a6557600080fd5b505afa158015610a79573d6000803e3d6000fd5b505050506040513d6020811015610a8f57600080fd5b50519050610a9d818361159c565b9350610aa761254e565b604080516060810182526001600160a01b0380891682526004805484516370a0823160e01b815230928101929092529351929360208086019491909316926370a082319260248082019391829003018186803b158015610b0657600080fd5b505afa158015610b1a573d6000803e3d6000fd5b505050506040513d6020811015610b3057600080fd5b505181526020908101969096526008805460018101825560009190915281517ff3f7a9fe364faab93b216da50a3214154f22a0a2b415b23a84c8169e8b636ee3600390920291820180546001600160a01b0319166001600160a01b03909216919091179055958101517ff3f7a9fe364faab93b216da50a3214154f22a0a2b415b23a84c8169e8b636ee4870155604001517ff3f7a9fe364faab93b216da50a3214154f22a0a2b415b23a84c8169e8b636ee5909501949094555050505050565b6004546001600160a01b031681565b6001600160a01b03811660009081526006602052604081208190815b600854811015610ce6576001600160a01b038516600090815260096020908152604080832084845290915290205460ff16610cde576000610ca960088381548110610c6257fe5b9060005260206000209060030201600101546104b3856000015460088681548110610c8957fe5b9060005260206000209060030201600201546115de90919063ffffffff16565b905060088281548110610cb857fe5b60009182526020909120600390910201546001600160a01b031694509250610ce9915050565b600101610c1b565b50505b915091565b600081831115610cff575081610d02565b50805b92915050565b6007546001600160a01b031681565b60008080805b600054811015610ec45760008181548110610d3457fe5b906000526020600020906004020160000154431015610d5257610ec4565b6000610d8360008381548110610d6457fe5b9060005260206000209060040201600101546000848154811061062057fe5b9050806002541115610d955750610ebc565b80431115610e0957610dfc60008381548110610dad57fe5b906000526020600020906004020160030154610df6610def600254600160008881548110610dd757fe5b90600052602060002090600402016000015403610cee565b849061159c565b906115de565b8401935060019250610eba565b8215610e6e57610e6560008381548110610e1f57fe5b906000526020600020906004020160030154610df6600160008681548110610e4357fe5b906000526020600020906004020160000154034361159c90919063ffffffff16565b84019350610eb4565b610eaf60008381548110610e7e57fe5b906000526020600020906004020160030154610df6610ea8600254600160008881548110610dd757fe5b439061159c565b840193505b50610ec4565b505b600101610d1d565b50909150505b90565b6001546001600160a01b03163314610f1d576040805162461bcd60e51b815260206004820152600e60248201526d37b7363ca1b7b73a3937b63632b960911b604482015290519081900360640190fd5b600a805460ff1916911515919091179055565b60025481565b6000805b600054811015610fb25760008181548110610f5157fe5b90600052602060002090600402016000015443118015610f9e5750610f9b60008281548110610f7c57fe5b9060005260206000209060040201600101546000838154811061062057fe5b43105b15610faa579050610eca565b600101610f3a565b5090565b6000811161100b576040805162461bcd60e51b815260206004820152601d60248201527f616d6f756e74206d757374206265206d6f7265207468616e207a65726f000000604482015290519081900360640190fd5b33600090815260066020526040902061102261125c565b80541561106c57600061105882600101546104b9670de0b6b3a76400006104b360055487600001546115de90919063ffffffff16565b9050801561106a5761106a3382611637565b505b805461107890836114f9565b8155600454611092906001600160a01b0316333085611f16565b60055481546110ae91670de0b6b3a7640000916104b3916115de565b600182015560408051838152905133917fe1fffcc4923d04b559f4d29a8bfc6cda04eb5b0d3c460751c2402c5c5cc9109c919081900360200190a25050565b6001600160a01b03811660009081526006602052604081208161110e610d17565b60048054604080516370a0823160e01b81523093810193909352519293506000926001600160a01b03909116916370a08231916024808301926020929190829003018186803b15801561116057600080fd5b505afa158015611174573d6000803e3d6000fd5b505050506040513d602081101561118a57600080fd5b505190508061119f57600093505050506111ff565b60006111cb6111c2836104b3606481605d610df68a670de0b6b3a76400006115de565b600554906114f9565b90506111f884600101546104b9670de0b6b3a76400006104b38589600001546115de90919063ffffffff16565b9450505050505b919050565b600a5460ff1681565b6003546001600160a01b031681565b6008818154811061122957fe5b60009182526020909120600390910201805460018201546002909201546001600160a01b03909116925083565b60055481565b600254431161126a576114b1565b61127333611f76565b60048054604080516370a0823160e01b81523093810193909352516000926001600160a01b03909216916370a08231916024808301926020929190829003018186803b1580156112c257600080fd5b505afa1580156112d6573d6000803e3d6000fd5b505050506040513d60208110156112ec57600080fd5b50519050806112ff5750436002556114b1565b6000611309610d17565b905080156114aa5760015460408051631d68877b60e11b815290516001600160a01b03909216916340c10f19918391633ad10ef691600480820192602092909190829003018186803b15801561135e57600080fd5b505afa158015611372573d6000803e3d6000fd5b505050506040513d602081101561138857600080fd5b505161139a60646104b38660076115de565b6040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050600060405180830381600087803b1580156113e057600080fd5b505af11580156113f4573d6000803e3d6000fd5b50506001546001600160a01b031691506340c10f1990503061141c60646104b386605d6115de565b6040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050600060405180830381600087803b15801561146257600080fd5b505af1158015611476573d6000803e3d6000fd5b505050506114a66111c2836104b360646104b3605d610df6670de0b6b3a7640000896115de90919063ffffffff16565b6005555b5050436002555b565b600081815481106114c057fe5b60009182526020909120600490910201805460018201546002830154600390930154919350919084565b6001546001600160a01b031681565b600082820183811015611553576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b9392505050565b600061155383836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250612043565b600061155383836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506120e5565b6000826115ed57506000610d02565b828202828482816115fa57fe5b04146115535760405162461bcd60e51b81526004018080602001828103825260218152602001806125a16021913960400191505060405180910390fd5b600354604080516370a0823160e01b815230600482015290516000926001600160a01b0316916370a08231916024808301926020929190829003018186803b15801561168257600080fd5b505afa158015611696573d6000803e3d6000fd5b505050506040513d60208110156116ac57600080fd5b5051905080821115611740576003546040805163a9059cbb60e01b81526001600160a01b038681166004830152602482018590529151919092169163a9059cbb9160448083019260209291908290030181600087803b15801561170e57600080fd5b505af1158015611722573d6000803e3d6000fd5b505050506040513d602081101561173857600080fd5b506117c39050565b6003546040805163a9059cbb60e01b81526001600160a01b038681166004830152602482018690529151919092169163a9059cbb9160448083019260209291908290030181600087803b15801561179657600080fd5b505af11580156117aa573d6000803e3d6000fd5b505050506040513d60208110156117c057600080fd5b50505b505050565b6004805460408051630dfe168160e01b815290516001600160a01b03909216926000928492630dfe16819281810192602092909190829003018186803b15801561181157600080fd5b505afa158015611825573d6000803e3d6000fd5b505050506040513d602081101561183b57600080fd5b50516040805163d21220a760e01b815290519192506000916001600160a01b0385169163d21220a7916004808301926020929190829003018186803b15801561188357600080fd5b505afa158015611897573d6000803e3d6000fd5b505050506040513d60208110156118ad57600080fd5b505160075460408051635d5155ef60e11b81526001600160a01b0386811660048301528085166024830152604482018990526001606483810182905260848401919091523060a4840152420160c483015282519495506000948594919091169263baa2abde9260e4808201939182900301818787803b15801561192f57600080fd5b505af1158015611943573d6000803e3d6000fd5b505050506040513d604081101561195957600080fd5b5080516020909101516003549193509150600090819081906001600160a01b03888116911614156119f25760035460408051630852cd8d60e31b81526004810188905290516001600160a01b03909216916342966c689160248082019260009290919082900301818387803b1580156119d157600080fd5b505af11580156119e5573d6000803e3d6000fd5b5050505060019250600191505b6003546001600160a01b0387811691161415611a765760035460408051630852cd8d60e31b81526004810187905290516001600160a01b03909216916342966c689160248082019260009290919082900301818387803b158015611a5557600080fd5b505af1158015611a69573d6000803e3d6000fd5b5050505060019250600190505b81611c9757600160009054906101000a90046001600160a01b03166001600160a01b031663526003446040518163ffffffff1660e01b815260040160206040518083038186803b158015611ac957600080fd5b505afa158015611add573d6000803e3d6000fd5b505050506040513d6020811015611af357600080fd5b50516001600160a01b038881169116148015611b0d575082155b15611c1357600160009054906101000a90046001600160a01b03166001600160a01b031663526003446040518163ffffffff1660e01b815260040160206040518083038186803b158015611b6057600080fd5b505afa158015611b74573d6000803e3d6000fd5b505050506040513d6020811015611b8a57600080fd5b50516040805163a9059cbb60e01b81526000600482018190526024820189905291516001600160a01b039093169263a9059cbb92604480840193602093929083900390910190829087803b158015611be157600080fd5b505af1158015611bf5573d6000803e3d6000fd5b505050506040513d6020811015611c0b57600080fd5b50611c979050565b866001600160a01b031663a9059cbb8b876040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050602060405180830381600087803b158015611c6a57600080fd5b505af1158015611c7e573d6000803e3d6000fd5b505050506040513d6020811015611c9457600080fd5b50505b80611eb857600160009054906101000a90046001600160a01b03166001600160a01b031663526003446040518163ffffffff1660e01b815260040160206040518083038186803b158015611cea57600080fd5b505afa158015611cfe573d6000803e3d6000fd5b505050506040513d6020811015611d1457600080fd5b50516001600160a01b038781169116148015611d2e575082155b15611e3457600160009054906101000a90046001600160a01b03166001600160a01b031663526003446040518163ffffffff1660e01b815260040160206040518083038186803b158015611d8157600080fd5b505afa158015611d95573d6000803e3d6000fd5b505050506040513d6020811015611dab57600080fd5b50516040805163a9059cbb60e01b81526000600482018190526024820188905291516001600160a01b039093169263a9059cbb92604480840193602093929083900390910190829087803b158015611e0257600080fd5b505af1158015611e16573d6000803e3d6000fd5b505050506040513d6020811015611e2c57600080fd5b50611eb89050565b856001600160a01b031663a9059cbb8b866040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050602060405180830381600087803b158015611e8b57600080fd5b505af1158015611e9f573d6000803e3d6000fd5b505050506040513d6020811015611eb557600080fd5b50505b50505050505050505050565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b1790526117c390849061213f565b604080516001600160a01b0380861660248301528416604482015260648082018490528251808303909101815260849091019091526020810180516001600160e01b03166323b872dd60e01b179052611f7090859061213f565b50505050565b6001600160a01b0381166000908152600660205260408120905b6008548110156117c3576001600160a01b038316600090815260096020908152604080832084845290915290205460ff1661203b576001600160a01b03831660009081526009602090815260408083208484529091528120805460ff1916600117905560088054612006919084908110610c6257fe5b90506120396008838154811061201857fe5b60009182526020909120600390910201546001600160a01b031685836121f0565b505b600101611f90565b600081836120cf5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561209457818101518382015260200161207c565b50505050905090810190601f1680156120c15780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816120db57fe5b0495945050505050565b600081848411156121375760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561209457818101518382015260200161207c565b505050900390565b6060612194826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b031661239c9092919063ffffffff16565b8051909150156117c3578080602001905160208110156121b357600080fd5b50516117c35760405162461bcd60e51b815260040180806020018281038252602a8152602001806125c2602a913960400191505060405180910390fd5b6000836001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b15801561223f57600080fd5b505afa158015612253573d6000803e3d6000fd5b505050506040513d602081101561226957600080fd5b50519050801580612278575081155b1561228357506117c3565b81811061231357836001600160a01b031663a9059cbb84846040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050602060405180830381600087803b1580156122e157600080fd5b505af11580156122f5573d6000803e3d6000fd5b505050506040513d602081101561230b57600080fd5b50611f709050565b836001600160a01b031663a9059cbb84836040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050602060405180830381600087803b15801561236a57600080fd5b505af115801561237e573d6000803e3d6000fd5b505050506040513d602081101561239457600080fd5b505050505050565b60606123ab84846000856123b3565b949350505050565b60606123be85612520565b61240f576040805162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015290519081900360640190fd5b60006060866001600160a01b031685876040518082805190602001908083835b6020831061244e5780518252601f19909201916020918201910161242f565b6001836020036101000a03801982511681845116808217855250505050505090500191505060006040518083038185875af1925050503d80600081146124b0576040519150601f19603f3d011682016040523d82523d6000602084013e6124b5565b606091505b509150915081156124c95791506123ab9050565b8051156124d95780518082602001fd5b60405162461bcd60e51b815260206004820181815286516024840152865187939192839260440191908501908083836000831561209457818101518382015260200161207c565b3b151590565b6040518060800160405280600081526020016000815260200160008152602001600081525090565b604051806060016040528060006001600160a01b031681526020016000815260200160008152509056fe7374617274696e67426c6f636b2073686f756c642062652067726561746572207468616e206e6f77536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f775361666545524332303a204552433230206f7065726174696f6e20646964206e6f742073756363656564a2646970667358221220ff52122295b553fc68a926029c9e5203999ad7f7a5f7293e97a4e09412c8767b64736f6c634300060c00337374617274696e67426c6f636b2073686f756c642062652067726561746572207468616e206e6f774f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573734f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572a264697066735822122006304148274af880c43418f2c6874816a01cdc129183d1852890e4410d3da67164736f6c634300060c0033000000000000000000000000c0ba369c8db6eb3924965e5c4fd0b4c1b91e305f0000000000000000000000005e977851f7a0a094d802fc072b743b2d1ca6b9cc000000000000000000000000fbeea1c75e4c4465cb2fccc9c6d6afe984558e20000000000000000000000000d408edf30ddeddea353accb987198129e95b9207

Deployed Bytecode

0x60806040523480156200001157600080fd5b50600436106200010c5760003560e01c806395899a8311620000a5578063b6c38432116200006f578063b6c38432146200038e578063c2ba474414620003b7578063d5226a1c14620003f4578063f2fde38b14620003fe576200010c565b806395899a8314620001b8578063970d20e914620001ea578063ac4afa381462000229578063ad3448771462000249576200010c565b80635c20cfe811620000e75780635c20cfe81462000172578063715018a6146200019a5780638da5cb5b14620001a457806392f2cff014620001ae576200010c565b80633ad10ef6146200011157806340c10f191462000137578063526003441462000168575b600080fd5b6200011b62000427565b604080516001600160a01b039092168252519081900360200190f35b62000166600480360360408110156200014f57600080fd5b506001600160a01b03813516906020013562000436565b005b6200011b6200051c565b62000166600480360360408110156200018a57600080fd5b508035906020013515156200052b565b6200016662000603565b6200011b620006a9565b6200011b620006b8565b6200016660048036036080811015620001d057600080fd5b5080359060208101359060408101359060600135620006c7565b62000166600480360360808110156200020257600080fd5b508035906001600160a01b03602082013581169160408101359160609091013516620007ae565b6200011b600480360360208110156200024157600080fd5b50356200087a565b62000166600480360360808110156200026157600080fd5b6001600160a01b03823516916020810135918101906060810160408201356401000000008111156200029257600080fd5b820183602082011115620002a557600080fd5b80359060200191846020830284011164010000000083111715620002c857600080fd5b91908080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525092959493602081019350359150506401000000008111156200031957600080fd5b8201836020820111156200032c57600080fd5b803590602001918460208302840111640100000000831117156200034f57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550620008a2945050505050565b6200016660048036036020811015620003a657600080fd5b50356001600160a01b031662000a7f565b620003e060048036036020811015620003cf57600080fd5b50356001600160a01b031662000afd565b604080519115158252519081900360200190f35b6200011b62000b12565b62000166600480360360208110156200041657600080fd5b50356001600160a01b031662000b21565b6003546001600160a01b031681565b3360009081526006602052604090205460ff1662000488576040805162461bcd60e51b815260206004820152600a6024820152696f6e6c7920706f6f6c7360b01b604482015290519081900360640190fd5b600154600554604080516323b872dd60e01b81526001600160a01b039283166004820152858316602482015260448101859052905191909216916323b872dd9160648083019260209291908290030181600087803b158015620004ea57600080fd5b505af1158015620004ff573d6000803e3d6000fd5b505050506040513d60208110156200051657600080fd5b50505050565b6004546001600160a01b031681565b6200053562000c1f565b6000546001600160a01b0390811691161462000587576040805162461bcd60e51b8152602060048201819052602482015260008051602062003bbc833981519152604482015290519081900360640190fd5b600282815481106200059557fe5b60009182526020822001546040805163500d235760e11b8152841515600482015290516001600160a01b039092169263a01a46ae9260248084019382900301818387803b158015620005e657600080fd5b505af1158015620005fb573d6000803e3d6000fd5b505050505050565b6200060d62000c1f565b6000546001600160a01b039081169116146200065f576040805162461bcd60e51b8152602060048201819052602482015260008051602062003bbc833981519152604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b6000546001600160a01b031690565b6005546001600160a01b031681565b620006d162000c1f565b6000546001600160a01b0390811691161462000723576040805162461bcd60e51b8152602060048201819052602482015260008051602062003bbc833981519152604482015290519081900360640190fd5b600284815481106200073157fe5b600091825260208220015460408051633be64ed760e01b815260048101879052602481018690526044810185905290516001600160a01b0390921692633be64ed79260648084019382900301818387803b1580156200078f57600080fd5b505af1158015620007a4573d6000803e3d6000fd5b5050505050505050565b620007b862000c1f565b6000546001600160a01b039081169116146200080a576040805162461bcd60e51b8152602060048201819052602482015260008051602062003bbc833981519152604482015290519081900360640190fd5b600284815481106200081857fe5b6000918252602082200154604080516317949d5f60e21b81526001600160a01b03878116600483015260248201879052858116604483015291519190921692635e52757c926064808201939182900301818387803b1580156200078f57600080fd5b600281815481106200088857fe5b6000918252602090912001546001600160a01b0316905081565b620008ac62000c1f565b6000546001600160a01b03908116911614620008fe576040805162461bcd60e51b8152602060048201819052602482015260008051602062003bbc833981519152604482015290519081900360640190fd5b600084848484604051620009129062000c23565b80856001600160a01b031681526020018481526020018060200180602001838103835285818151815260200191508051906020019060200280838360005b838110156200096a57818101518382015260200162000950565b50505050905001838103825284818151815260200191508051906020019060200280838360005b83811015620009ab57818101518382015260200162000991565b505050509050019650505050505050604051809103906000f080158015620009d7573d6000803e3d6000fd5b506002805460018082019092557f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace0180546001600160a01b0319166001600160a01b03848116918217909255600081815260066020908152604091829020805460ff19169095179094558051928a16835251939450927f77948cb83ef3caff9ac13dfab1ea1f8a6875c98370287ce587f5dbc74cc5b6b0929181900390910190a25050505050565b62000a8962000c1f565b6000546001600160a01b0390811691161462000adb576040805162461bcd60e51b8152602060048201819052602482015260008051602062003bbc833981519152604482015290519081900360640190fd5b600580546001600160a01b0319166001600160a01b0392909216919091179055565b60066020526000908152604090205460ff1681565b6001546001600160a01b031681565b62000b2b62000c1f565b6000546001600160a01b0390811691161462000b7d576040805162461bcd60e51b8152602060048201819052602482015260008051602062003bbc833981519152604482015290519081900360640190fd5b6001600160a01b03811662000bc45760405162461bcd60e51b815260040180806020018281038252602681526020018062003b966026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b3390565b612f648062000c328339019056fe6080604052600780546001600160a01b031916737a250d5630b4cf539739df2c5dacb4c659f2488d1790553480156200003757600080fd5b5060405162002f6438038062002f64833981810160405260808110156200005d57600080fd5b815160208301516040808501805191519395929483019291846401000000008211156200008957600080fd5b9083019060208201858111156200009f57600080fd5b8251866020820283011164010000000082111715620000bd57600080fd5b82525081516020918201928201910280838360005b83811015620000ec578181015183820152602001620000d2565b50505050905001604052602001805160405193929190846401000000008211156200011657600080fd5b9083019060208201858111156200012c57600080fd5b82518660208202830111640100000000821117156200014a57600080fd5b82525081516020918201928201910280838360005b83811015620001795781810151838201526020016200015f565b505050509050016040525050506000825111620001ca576040805162461bcd60e51b815260206004820152600a602482015269656d706c79206461746160b01b604482015290519081900360640190fd5b805182511462000210576040805162461bcd60e51b815260206004820152600c60248201526b696e76616c6964206461746160a01b604482015290519081900360640190fd5b600180546001600160a01b031916331790819055604080516335489a8760e21b815290516001600160a01b03929092169163d5226a1c91600480820192602092909190829003018186803b1580156200026857600080fd5b505afa1580156200027d573d6000803e3d6000fd5b505050506040513d60208110156200029457600080fd5b5051600380546001600160a01b03199081166001600160a01b0393841617909155600480549091169186169190911790558151620003049084908490600090620002da57fe5b602002602001015183600081518110620002f057fe5b60200260200101516200043c60201b60201c565b600062000335836000815181106200031857fe5b602002602001015185620006e960201b620014f91790919060201c565b905060015b8351811015620003a4576200036b828583815181106200035657fe5b6020026020010151858481518110620002f057fe5b620003998482815181106200037c57fe5b602002602001015183620006e960201b620014f91790919060201c565b91506001016200033a565b506007546040805163095ea7b360e01b81526001600160a01b039283166004820152600019602482015290519187169163095ea7b3916044808201926020929091908290030181600087803b158015620003fd57600080fd5b505af115801562000412573d6000803e3d6000fd5b505050506040513d60208110156200042957600080fd5b505050600292909255506200090b915050565b6001546001600160a01b031633146200048d576040805162461bcd60e51b815260206004820152600e60248201526d37b7363ca1b7b73a3937b63632b960911b604482015290519081900360640190fd5b43831015620004ce5760405162461bcd60e51b815260040180806020018281038252602881526020018062002f3c6028913960400191505060405180910390fd5b600054156200059257600080546200053e91906000198101908110620004f057fe5b9060005260206000209060040201600101546000600160008054905003815481106200051857fe5b906000526020600020906004020160000154620006e960201b620014f91790919060201c565b831162000592576040805162461bcd60e51b815260206004820152601c60248201527f74776f20706572696f647320696e207468652073616d652074696d6500000000604482015290519081900360640190fd5b6000620005ae83836200074b60201b6200155a1790919060201c565b9050620005ba620008e3565b6040518060800160405280868152602001620005e66001876200079560201b6200159c1790919060201c565b8152602080820186905260409182018590526000805460018101825590805283517f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e563600490920291820155838201517f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e564820155838301517f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e56582015560608401517f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e5669091015581518681529151929350869288927f2c1ba73d1c003cfaa21fc5841652471b22221e83b5b01a9f7dc54de46e8ed64392908290030190a35050505050565b60008282018381101562000744576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b9392505050565b60006200074483836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250620007df60201b60201c565b60006200074483836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506200088660201b60201c565b600081836200086f5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156200083357818101518382015260200162000819565b50505050905090810190601f168015620008615780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816200087c57fe5b0495945050505050565b60008184841115620008db5760405162461bcd60e51b81526020600482018181528351602484015283519092839260449091019190850190808383600083156200083357818101518382015260200162000819565b505050900390565b6040518060800160405280600081526020016000815260200160008152602001600081525090565b612621806200091b6000396000f3fe608060405234801561001057600080fd5b50600436106101425760003560e01c8063a9f8d181116100b8578063d5226a1c1161007c578063d5226a1c14610361578063d95894d814610369578063da62fc28146103ae578063e3161ddd146103b6578063ea4a1104146103be578063f77c47911461040157610142565b8063a9f8d181146102f2578063b4f5a21a146102fa578063b6b55f2514610302578063c67106291461031f578063cb9a8c7e1461034557610142565b80635fcbd2851161010a5780635fcbd28514610221578063614ad28a146102455780636d5433e61461028e578063735de9f7146102c35780639f331649146102cb578063a01a46ae146102d357610142565b80631959a002146101475780632e1a7d4d146101865780633be64ed7146101a55780635312ea8e146101ce5780635e52757c146101eb575b600080fd5b61016d6004803603602081101561015d57600080fd5b50356001600160a01b0316610409565b6040805192835260208301919091528051918290030190f35b6101a36004803603602081101561019c57600080fd5b5035610422565b005b6101a3600480360360608110156101bb57600080fd5b508035906020810135906040013561054b565b6101a3600480360360208110156101e457600080fd5b50356107c0565b6101a36004803603606081101561020157600080fd5b506001600160a01b0381358116916020810135916040909101351661087a565b610229610bf0565b604080516001600160a01b039092168252519081900360200190f35b61026b6004803603602081101561025b57600080fd5b50356001600160a01b0316610bff565b604080516001600160a01b03909316835260208301919091528051918290030190f35b6102b1600480360360408110156102a457600080fd5b5080359060200135610cee565b60408051918252519081900360200190f35b610229610d08565b6102b1610d17565b6101a3600480360360208110156102e957600080fd5b50351515610ecd565b6102b1610f30565b6102b1610f36565b6101a36004803603602081101561031857600080fd5b5035610fb6565b6102b16004803603602081101561033557600080fd5b50356001600160a01b03166110ed565b61034d611204565b604080519115158252519081900360200190f35b61022961120d565b6103866004803603602081101561037f57600080fd5b503561121c565b604080516001600160a01b039094168452602084019290925282820152519081900360600190f35b6102b1611256565b6101a361125c565b6103db600480360360208110156103d457600080fd5b50356114b3565b604080519485526020850193909352838301919091526060830152519081900360800190f35b6102296114ea565b6006602052600090815260409020805460019091015482565b336000908152600660205260409020805482111561047c576040805162461bcd60e51b81526020600482015260126024820152711dda5d1a191c985dce881b9bdd0819dbdbd960721b604482015290519081900360640190fd5b61048461125c565b60006104bf82600101546104b9670de0b6b3a76400006104b360055487600001546115de90919063ffffffff16565b9061155a565b9061159c565b905080156104d1576104d13382611637565b82156104ef5781546104e3908461159c565b82556104ef33846117c8565b600554825461050b91670de0b6b3a7640000916104b3916115de565b600183015560408051848152905133917f884edad9ce6fa2440d8a54cc123490eb96d2768479d49ff9c7366125a9424364919081900360200190a2505050565b6001546001600160a01b0316331461059b576040805162461bcd60e51b815260206004820152600e60248201526d37b7363ca1b7b73a3937b63632b960911b604482015290519081900360640190fd5b438310156105da5760405162461bcd60e51b81526004018080602001828103825260288152602001806125796028913960400191505060405180910390fd5b6000541561068a5760008054610637919060001981019081106105f957fe5b90600052602060002090600402016001015460006001600080549050038154811061062057fe5b6000918252602090912060049091020154906114f9565b831161068a576040805162461bcd60e51b815260206004820152601c60248201527f74776f20706572696f647320696e207468652073616d652074696d6500000000604482015290519081900360640190fd5b6000610696828461155a565b90506106a0612526565b6040805160808101909152858152602081016106bd86600161159c565b8152602080820186905260409182018590526000805460018101825590805283517f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e563600490920291820155838201517f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e564820155838301517f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e56582015560608401517f290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e5669091015581518681529151929350869288927f2c1ba73d1c003cfaa21fc5841652471b22221e83b5b01a9f7dc54de46e8ed64392908290030190a35050505050565b600a5460ff1661080b576040805162461bcd60e51b8152602060048201526011602482015270199d5b98dd1a5bdb88191a5cd8589b1959607a1b604482015290519081900360640190fd5b33600081815260066020526040902080546004549192610834926001600160a01b031691611ec4565b80546040805191825251839133917fbb757047c2b5f3974fe26b7c10f732e7bce710b0952a71082702781e62ae05959181900360200190a3600080825560019091015550565b6001546001600160a01b031633146108ca576040805162461bcd60e51b815260206004820152600e60248201526d37b7363ca1b7b73a3937b63632b960911b604482015290519081900360640190fd5b600854603211610918576040805162461bcd60e51b8152602060048201526014602482015273195e18d95959081c995d995b9d59481b1a5b5a5d60621b604482015290519081900360640190fd5b6000836001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b15801561096757600080fd5b505afa15801561097b573d6000803e3d6000fd5b505050506040513d602081101561099157600080fd5b5051604080516323b872dd60e01b81526001600160a01b038581166004830152306024830152604482018790529151929350908616916323b872dd916064808201926020929091908290030181600087803b1580156109ef57600080fd5b505af1158015610a03573d6000803e3d6000fd5b505050506040513d6020811015610a1957600080fd5b5050604080516370a0823160e01b815230600482015290516000916001600160a01b038716916370a0823191602480820192602092909190829003018186803b158015610a6557600080fd5b505afa158015610a79573d6000803e3d6000fd5b505050506040513d6020811015610a8f57600080fd5b50519050610a9d818361159c565b9350610aa761254e565b604080516060810182526001600160a01b0380891682526004805484516370a0823160e01b815230928101929092529351929360208086019491909316926370a082319260248082019391829003018186803b158015610b0657600080fd5b505afa158015610b1a573d6000803e3d6000fd5b505050506040513d6020811015610b3057600080fd5b505181526020908101969096526008805460018101825560009190915281517ff3f7a9fe364faab93b216da50a3214154f22a0a2b415b23a84c8169e8b636ee3600390920291820180546001600160a01b0319166001600160a01b03909216919091179055958101517ff3f7a9fe364faab93b216da50a3214154f22a0a2b415b23a84c8169e8b636ee4870155604001517ff3f7a9fe364faab93b216da50a3214154f22a0a2b415b23a84c8169e8b636ee5909501949094555050505050565b6004546001600160a01b031681565b6001600160a01b03811660009081526006602052604081208190815b600854811015610ce6576001600160a01b038516600090815260096020908152604080832084845290915290205460ff16610cde576000610ca960088381548110610c6257fe5b9060005260206000209060030201600101546104b3856000015460088681548110610c8957fe5b9060005260206000209060030201600201546115de90919063ffffffff16565b905060088281548110610cb857fe5b60009182526020909120600390910201546001600160a01b031694509250610ce9915050565b600101610c1b565b50505b915091565b600081831115610cff575081610d02565b50805b92915050565b6007546001600160a01b031681565b60008080805b600054811015610ec45760008181548110610d3457fe5b906000526020600020906004020160000154431015610d5257610ec4565b6000610d8360008381548110610d6457fe5b9060005260206000209060040201600101546000848154811061062057fe5b9050806002541115610d955750610ebc565b80431115610e0957610dfc60008381548110610dad57fe5b906000526020600020906004020160030154610df6610def600254600160008881548110610dd757fe5b90600052602060002090600402016000015403610cee565b849061159c565b906115de565b8401935060019250610eba565b8215610e6e57610e6560008381548110610e1f57fe5b906000526020600020906004020160030154610df6600160008681548110610e4357fe5b906000526020600020906004020160000154034361159c90919063ffffffff16565b84019350610eb4565b610eaf60008381548110610e7e57fe5b906000526020600020906004020160030154610df6610ea8600254600160008881548110610dd757fe5b439061159c565b840193505b50610ec4565b505b600101610d1d565b50909150505b90565b6001546001600160a01b03163314610f1d576040805162461bcd60e51b815260206004820152600e60248201526d37b7363ca1b7b73a3937b63632b960911b604482015290519081900360640190fd5b600a805460ff1916911515919091179055565b60025481565b6000805b600054811015610fb25760008181548110610f5157fe5b90600052602060002090600402016000015443118015610f9e5750610f9b60008281548110610f7c57fe5b9060005260206000209060040201600101546000838154811061062057fe5b43105b15610faa579050610eca565b600101610f3a565b5090565b6000811161100b576040805162461bcd60e51b815260206004820152601d60248201527f616d6f756e74206d757374206265206d6f7265207468616e207a65726f000000604482015290519081900360640190fd5b33600090815260066020526040902061102261125c565b80541561106c57600061105882600101546104b9670de0b6b3a76400006104b360055487600001546115de90919063ffffffff16565b9050801561106a5761106a3382611637565b505b805461107890836114f9565b8155600454611092906001600160a01b0316333085611f16565b60055481546110ae91670de0b6b3a7640000916104b3916115de565b600182015560408051838152905133917fe1fffcc4923d04b559f4d29a8bfc6cda04eb5b0d3c460751c2402c5c5cc9109c919081900360200190a25050565b6001600160a01b03811660009081526006602052604081208161110e610d17565b60048054604080516370a0823160e01b81523093810193909352519293506000926001600160a01b03909116916370a08231916024808301926020929190829003018186803b15801561116057600080fd5b505afa158015611174573d6000803e3d6000fd5b505050506040513d602081101561118a57600080fd5b505190508061119f57600093505050506111ff565b60006111cb6111c2836104b3606481605d610df68a670de0b6b3a76400006115de565b600554906114f9565b90506111f884600101546104b9670de0b6b3a76400006104b38589600001546115de90919063ffffffff16565b9450505050505b919050565b600a5460ff1681565b6003546001600160a01b031681565b6008818154811061122957fe5b60009182526020909120600390910201805460018201546002909201546001600160a01b03909116925083565b60055481565b600254431161126a576114b1565b61127333611f76565b60048054604080516370a0823160e01b81523093810193909352516000926001600160a01b03909216916370a08231916024808301926020929190829003018186803b1580156112c257600080fd5b505afa1580156112d6573d6000803e3d6000fd5b505050506040513d60208110156112ec57600080fd5b50519050806112ff5750436002556114b1565b6000611309610d17565b905080156114aa5760015460408051631d68877b60e11b815290516001600160a01b03909216916340c10f19918391633ad10ef691600480820192602092909190829003018186803b15801561135e57600080fd5b505afa158015611372573d6000803e3d6000fd5b505050506040513d602081101561138857600080fd5b505161139a60646104b38660076115de565b6040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050600060405180830381600087803b1580156113e057600080fd5b505af11580156113f4573d6000803e3d6000fd5b50506001546001600160a01b031691506340c10f1990503061141c60646104b386605d6115de565b6040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050600060405180830381600087803b15801561146257600080fd5b505af1158015611476573d6000803e3d6000fd5b505050506114a66111c2836104b360646104b3605d610df6670de0b6b3a7640000896115de90919063ffffffff16565b6005555b5050436002555b565b600081815481106114c057fe5b60009182526020909120600490910201805460018201546002830154600390930154919350919084565b6001546001600160a01b031681565b600082820183811015611553576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b9392505050565b600061155383836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250612043565b600061155383836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506120e5565b6000826115ed57506000610d02565b828202828482816115fa57fe5b04146115535760405162461bcd60e51b81526004018080602001828103825260218152602001806125a16021913960400191505060405180910390fd5b600354604080516370a0823160e01b815230600482015290516000926001600160a01b0316916370a08231916024808301926020929190829003018186803b15801561168257600080fd5b505afa158015611696573d6000803e3d6000fd5b505050506040513d60208110156116ac57600080fd5b5051905080821115611740576003546040805163a9059cbb60e01b81526001600160a01b038681166004830152602482018590529151919092169163a9059cbb9160448083019260209291908290030181600087803b15801561170e57600080fd5b505af1158015611722573d6000803e3d6000fd5b505050506040513d602081101561173857600080fd5b506117c39050565b6003546040805163a9059cbb60e01b81526001600160a01b038681166004830152602482018690529151919092169163a9059cbb9160448083019260209291908290030181600087803b15801561179657600080fd5b505af11580156117aa573d6000803e3d6000fd5b505050506040513d60208110156117c057600080fd5b50505b505050565b6004805460408051630dfe168160e01b815290516001600160a01b03909216926000928492630dfe16819281810192602092909190829003018186803b15801561181157600080fd5b505afa158015611825573d6000803e3d6000fd5b505050506040513d602081101561183b57600080fd5b50516040805163d21220a760e01b815290519192506000916001600160a01b0385169163d21220a7916004808301926020929190829003018186803b15801561188357600080fd5b505afa158015611897573d6000803e3d6000fd5b505050506040513d60208110156118ad57600080fd5b505160075460408051635d5155ef60e11b81526001600160a01b0386811660048301528085166024830152604482018990526001606483810182905260848401919091523060a4840152420160c483015282519495506000948594919091169263baa2abde9260e4808201939182900301818787803b15801561192f57600080fd5b505af1158015611943573d6000803e3d6000fd5b505050506040513d604081101561195957600080fd5b5080516020909101516003549193509150600090819081906001600160a01b03888116911614156119f25760035460408051630852cd8d60e31b81526004810188905290516001600160a01b03909216916342966c689160248082019260009290919082900301818387803b1580156119d157600080fd5b505af11580156119e5573d6000803e3d6000fd5b5050505060019250600191505b6003546001600160a01b0387811691161415611a765760035460408051630852cd8d60e31b81526004810187905290516001600160a01b03909216916342966c689160248082019260009290919082900301818387803b158015611a5557600080fd5b505af1158015611a69573d6000803e3d6000fd5b5050505060019250600190505b81611c9757600160009054906101000a90046001600160a01b03166001600160a01b031663526003446040518163ffffffff1660e01b815260040160206040518083038186803b158015611ac957600080fd5b505afa158015611add573d6000803e3d6000fd5b505050506040513d6020811015611af357600080fd5b50516001600160a01b038881169116148015611b0d575082155b15611c1357600160009054906101000a90046001600160a01b03166001600160a01b031663526003446040518163ffffffff1660e01b815260040160206040518083038186803b158015611b6057600080fd5b505afa158015611b74573d6000803e3d6000fd5b505050506040513d6020811015611b8a57600080fd5b50516040805163a9059cbb60e01b81526000600482018190526024820189905291516001600160a01b039093169263a9059cbb92604480840193602093929083900390910190829087803b158015611be157600080fd5b505af1158015611bf5573d6000803e3d6000fd5b505050506040513d6020811015611c0b57600080fd5b50611c979050565b866001600160a01b031663a9059cbb8b876040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050602060405180830381600087803b158015611c6a57600080fd5b505af1158015611c7e573d6000803e3d6000fd5b505050506040513d6020811015611c9457600080fd5b50505b80611eb857600160009054906101000a90046001600160a01b03166001600160a01b031663526003446040518163ffffffff1660e01b815260040160206040518083038186803b158015611cea57600080fd5b505afa158015611cfe573d6000803e3d6000fd5b505050506040513d6020811015611d1457600080fd5b50516001600160a01b038781169116148015611d2e575082155b15611e3457600160009054906101000a90046001600160a01b03166001600160a01b031663526003446040518163ffffffff1660e01b815260040160206040518083038186803b158015611d8157600080fd5b505afa158015611d95573d6000803e3d6000fd5b505050506040513d6020811015611dab57600080fd5b50516040805163a9059cbb60e01b81526000600482018190526024820188905291516001600160a01b039093169263a9059cbb92604480840193602093929083900390910190829087803b158015611e0257600080fd5b505af1158015611e16573d6000803e3d6000fd5b505050506040513d6020811015611e2c57600080fd5b50611eb89050565b856001600160a01b031663a9059cbb8b866040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050602060405180830381600087803b158015611e8b57600080fd5b505af1158015611e9f573d6000803e3d6000fd5b505050506040513d6020811015611eb557600080fd5b50505b50505050505050505050565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b1790526117c390849061213f565b604080516001600160a01b0380861660248301528416604482015260648082018490528251808303909101815260849091019091526020810180516001600160e01b03166323b872dd60e01b179052611f7090859061213f565b50505050565b6001600160a01b0381166000908152600660205260408120905b6008548110156117c3576001600160a01b038316600090815260096020908152604080832084845290915290205460ff1661203b576001600160a01b03831660009081526009602090815260408083208484529091528120805460ff1916600117905560088054612006919084908110610c6257fe5b90506120396008838154811061201857fe5b60009182526020909120600390910201546001600160a01b031685836121f0565b505b600101611f90565b600081836120cf5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561209457818101518382015260200161207c565b50505050905090810190601f1680156120c15780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816120db57fe5b0495945050505050565b600081848411156121375760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561209457818101518382015260200161207c565b505050900390565b6060612194826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b031661239c9092919063ffffffff16565b8051909150156117c3578080602001905160208110156121b357600080fd5b50516117c35760405162461bcd60e51b815260040180806020018281038252602a8152602001806125c2602a913960400191505060405180910390fd5b6000836001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b15801561223f57600080fd5b505afa158015612253573d6000803e3d6000fd5b505050506040513d602081101561226957600080fd5b50519050801580612278575081155b1561228357506117c3565b81811061231357836001600160a01b031663a9059cbb84846040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050602060405180830381600087803b1580156122e157600080fd5b505af11580156122f5573d6000803e3d6000fd5b505050506040513d602081101561230b57600080fd5b50611f709050565b836001600160a01b031663a9059cbb84836040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050602060405180830381600087803b15801561236a57600080fd5b505af115801561237e573d6000803e3d6000fd5b505050506040513d602081101561239457600080fd5b505050505050565b60606123ab84846000856123b3565b949350505050565b60606123be85612520565b61240f576040805162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015290519081900360640190fd5b60006060866001600160a01b031685876040518082805190602001908083835b6020831061244e5780518252601f19909201916020918201910161242f565b6001836020036101000a03801982511681845116808217855250505050505090500191505060006040518083038185875af1925050503d80600081146124b0576040519150601f19603f3d011682016040523d82523d6000602084013e6124b5565b606091505b509150915081156124c95791506123ab9050565b8051156124d95780518082602001fd5b60405162461bcd60e51b815260206004820181815286516024840152865187939192839260440191908501908083836000831561209457818101518382015260200161207c565b3b151590565b6040518060800160405280600081526020016000815260200160008152602001600081525090565b604051806060016040528060006001600160a01b031681526020016000815260200160008152509056fe7374617274696e67426c6f636b2073686f756c642062652067726561746572207468616e206e6f77536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f775361666545524332303a204552433230206f7065726174696f6e20646964206e6f742073756363656564a2646970667358221220ff52122295b553fc68a926029c9e5203999ad7f7a5f7293e97a4e09412c8767b64736f6c634300060c00337374617274696e67426c6f636b2073686f756c642062652067726561746572207468616e206e6f774f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573734f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572a264697066735822122006304148274af880c43418f2c6874816a01cdc129183d1852890e4410d3da67164736f6c634300060c0033

Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)

000000000000000000000000c0ba369c8db6eb3924965e5c4fd0b4c1b91e305f0000000000000000000000005e977851f7a0a094d802fc072b743b2d1ca6b9cc000000000000000000000000fbeea1c75e4c4465cb2fccc9c6d6afe984558e20000000000000000000000000d408edf30ddeddea353accb987198129e95b9207

-----Decoded View---------------
Arg [0] : _duckTokenAddress (address): 0xC0bA369c8Db6eB3924965e5c4FD0b4C1B91e305F
Arg [1] : _devAddress (address): 0x5E977851f7A0A094D802FC072b743b2D1Ca6b9cC
Arg [2] : _ddimTokenAddress (address): 0xFbEEa1C75E4c4465CB2FCCc9c6d6afe984558E20
Arg [3] : _drainAddress (address): 0xD408EdF30DdEdDEA353AccB987198129E95B9207

-----Encoded View---------------
4 Constructor Arguments found :
Arg [0] : 000000000000000000000000c0ba369c8db6eb3924965e5c4fd0b4c1b91e305f
Arg [1] : 0000000000000000000000005e977851f7a0a094d802fc072b743b2d1ca6b9cc
Arg [2] : 000000000000000000000000fbeea1c75e4c4465cb2fccc9c6d6afe984558e20
Arg [3] : 000000000000000000000000d408edf30ddeddea353accb987198129e95b9207


Deployed Bytecode Sourcemap

33520:2242:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;33670:25;;;:::i;:::-;;;;-1:-1:-1;;;;;33670:25:0;;;;;;;;;;;;;;35600:159;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;35600:159:0;;;;;;;;:::i;:::-;;33774:31;;;:::i;35381:158::-;;;;;;;;;;;;;;;;-1:-1:-1;35381:158:0;;;;;;;;;:::i;20249:148::-;;;:::i;19607:79::-;;;:::i;33812:27::-;;;:::i;34907:188::-;;;;;;;;;;;;;;;;-1:-1:-1;34907:188:0;;;;;;;;;;;;;;;;;:::i;35177:196::-;;;;;;;;;;;;;;;;-1:-1:-1;35177:196:0;;;-1:-1:-1;;;;;35177:196:0;;;;;;;;;;;;;;;;;;;:::i;33638:19::-;;;;;;;;;;;;;;;;-1:-1:-1;33638:19:0;;:::i;34480:328::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;34480:328:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;34480:328:0;;;;;;;;-1:-1:-1;34480:328:0;;-1:-1:-1;;34480:328:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;34480:328:0;;-1:-1:-1;34480:328:0;;-1:-1:-1;;;;;34480:328:0:i;34299:112::-;;;;;;;;;;;;;;;;-1:-1:-1;34299:112:0;-1:-1:-1;;;;;34299:112:0;;:::i;33883:39::-;;;;;;;;;;;;;;;;-1:-1:-1;33883:39:0;-1:-1:-1;;;;;33883:39:0;;:::i;:::-;;;;;;;;;;;;;;;;;;33587:21;;;:::i;20552:244::-;;;;;;;;;;;;;;;;-1:-1:-1;20552:244:0;-1:-1:-1;;;;;20552:244:0;;:::i;33670:25::-;;;-1:-1:-1;;;;;33670:25:0;;:::o;35600:159::-;35672:10;35664:19;;;;:7;:19;;;;;;;;35656:42;;;;;-1:-1:-1;;;35656:42:0;;;;;;;;;;;;-1:-1:-1;;;35656:42:0;;;;;;;;;;;;;;;35709:4;;35727:12;;35709:42;;;-1:-1:-1;;;35709:42:0;;-1:-1:-1;;;;;35727:12:0;;;35709:42;;;;;;;;;;;;;;;;;;;:4;;;;;:17;;:42;;;;;;;;;;;;;;:4;;:42;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;35600:159:0:o;33774:31::-;;;-1:-1:-1;;;;;33774:31:0;;:::o;35381:158::-;19829:12;:10;:12::i;:::-;19819:6;;-1:-1:-1;;;;;19819:6:0;;;:22;;;19811:67;;;;;-1:-1:-1;;;19811:67:0;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;19811:67:0;;;;;;;;;;;;;;;35477:5:::1;35483:9;35477:16;;;;;;;;;::::0;;;::::1;::::0;;::::1;::::0;:54:::1;::::0;;-1:-1:-1;;;35477:54:0;;;::::1;;;::::0;::::1;::::0;;;-1:-1:-1;;;;;35477:16:0;;::::1;::::0;:46:::1;::::0;:54;;;;;;;;;;:16;;:54;::::1;;::::0;::::1;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;35381:158:::0;;:::o;20249:148::-;19829:12;:10;:12::i;:::-;19819:6;;-1:-1:-1;;;;;19819:6:0;;;:22;;;19811:67;;;;;-1:-1:-1;;;19811:67:0;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;19811:67:0;;;;;;;;;;;;;;;20356:1:::1;20340:6:::0;;20319:40:::1;::::0;-1:-1:-1;;;;;20340:6:0;;::::1;::::0;20319:40:::1;::::0;20356:1;;20319:40:::1;20387:1;20370:19:::0;;-1:-1:-1;;;;;;20370:19:0::1;::::0;;20249:148::o;19607:79::-;19645:7;19672:6;-1:-1:-1;;;;;19672:6:0;19607:79;:::o;33812:27::-;;;-1:-1:-1;;;;;33812:27:0;;:::o;34907:188::-;19829:12;:10;:12::i;:::-;19819:6;;-1:-1:-1;;;;;19819:6:0;;;:22;;;19811:67;;;;;-1:-1:-1;;;19811:67:0;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;19811:67:0;;;;;;;;;;;;;;;35023:5:::1;35029:9;35023:16;;;;;;;;;::::0;;;::::1;::::0;;::::1;::::0;:64:::1;::::0;;-1:-1:-1;;;35023:64:0;;::::1;::::0;::::1;::::0;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;35023:16:0;;::::1;::::0;:26:::1;::::0;:64;;;;;;;;;;:16;;:64;::::1;;::::0;::::1;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;34907:188:::0;;;;:::o;35177:196::-;19829:12;:10;:12::i;:::-;19819:6;;-1:-1:-1;;;;;19819:6:0;;;:22;;;19811:67;;;;;-1:-1:-1;;;19811:67:0;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;19811:67:0;;;;;;;;;;;;;;;35300:5:::1;35306:9;35300:16;;;;;;;;;::::0;;;::::1;::::0;;::::1;::::0;:65:::1;::::0;;-1:-1:-1;;;35300:65:0;;-1:-1:-1;;;;;35300:65:0;;::::1;;::::0;::::1;::::0;;;;;;;;;::::1;::::0;;;;;;:16;;;::::1;::::0;:27:::1;::::0;:65;;;;;;;;;;;:16;;:65;::::1;;::::0;::::1;;;;::::0;::::1;33638:19:::0;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;33638:19:0;;-1:-1:-1;33638:19:0;:::o;34480:328::-;19829:12;:10;:12::i;:::-;19819:6;;-1:-1:-1;;;;;19819:6:0;;;:22;;;19811:67;;;;;-1:-1:-1;;;19811:67:0;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;19811:67:0;;;;;;;;;;;;;;;34615:9:::1;34636:7;34645:13;34660:6;34668:15;34627:57;;;;;:::i;:::-;;;-1:-1:-1::0;;;;;34627:57:0::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;;::::1;::::0;;;::::1;::::0;::::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;;::::1;::::0;;;::::1;::::0;::::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;::::1;;;;;-1:-1:-1::0;34695:5:0::1;:16:::0;;::::1;::::0;;::::1;::::0;;;;::::1;::::0;;-1:-1:-1;;;;;;34695:16:0::1;-1:-1:-1::0;;;;;34695:16:0;;::::1;::::0;;::::1;::::0;;;-1:-1:-1;34724:22:0;;;:7:::1;34695:16;34724:22:::0;;;;;;;;:29;;-1:-1:-1;;34724:29:0::1;::::0;;::::1;::::0;;;34769:31;;;;::::1;::::0;;;34695:16;;-1:-1:-1;34695:16:0;34769:31:::1;::::0;;;;;;;;;::::1;19889:1;34480:328:::0;;;;:::o;34299:112::-;19829:12;:10;:12::i;:::-;19819:6;;-1:-1:-1;;;;;19819:6:0;;;:22;;;19811:67;;;;;-1:-1:-1;;;19811:67:0;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;19811:67:0;;;;;;;;;;;;;;;34375:12:::1;:28:::0;;-1:-1:-1;;;;;;34375:28:0::1;-1:-1:-1::0;;;;;34375:28:0;;;::::1;::::0;;;::::1;::::0;;34299:112::o;33883:39::-;;;;;;;;;;;;;;;:::o;33587:21::-;;;-1:-1:-1;;;;;33587:21:0;;:::o;20552:244::-;19829:12;:10;:12::i;:::-;19819:6;;-1:-1:-1;;;;;19819:6:0;;;:22;;;19811:67;;;;;-1:-1:-1;;;19811:67:0;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;19811:67:0;;;;;;;;;;;;;;;-1:-1:-1;;;;;20641:22:0;::::1;20633:73;;;;-1:-1:-1::0;;;20633:73:0::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;20743:6;::::0;;20722:38:::1;::::0;-1:-1:-1;;;;;20722:38:0;;::::1;::::0;20743:6;::::1;::::0;20722:38:::1;::::0;::::1;20771:6;:17:::0;;-1:-1:-1;;;;;;20771:17:0::1;-1:-1:-1::0;;;;;20771:17:0;;;::::1;::::0;;;::::1;::::0;;20552:244::o;18243:106::-;18331:10;18243:106;:::o;-1:-1:-1:-;;;;;;;;:::o

Swarm Source

ipfs://06304148274af880c43418f2c6874816a01cdc129183d1852890e4410d3da671

Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading
Loading...
Loading

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
Loading...
Loading
[ Download: CSV Export  ]

A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.