Contract 0x321f653eed006ad1c29d174e17d96351bde22649 2

 

Contract Overview

Balance:
0 ETH

ETH Value:
$0.00

Token:
Txn Hash Method
Block
From
To
Value [Txn Fee]
0x0096bd6e11aca3059a95fff8176746e13859c6d4aea165654c5f43e8a118bb1fMint And Stake G...243477772022-09-13 3:51:5116 days 16 hrs ago0x10a2a9905e97789074e51c79800747b6960e1131 IN  0x321f653eed006ad1c29d174e17d96351bde226490 ETH0.00001161
0x091062430a1651527952f88784c9e123c0a794965551638208ad23b42b189cc9Set Gov2449112021-09-01 15:25:08393 days 5 hrs agoGMX: Deployer IN  0x321f653eed006ad1c29d174e17d96351bde226490 ETH0.000757334761 ETH
0x748f44e5368c28212490c75cafe474ba23ddec8c744983e5493d846031b10eebSet Handler2271382021-08-31 7:53:21394 days 12 hrs agoGMX: Deployer IN  0x321f653eed006ad1c29d174e17d96351bde226490 ETH0.000933976907 ETH
0x9bc58c58f9258e9b1f4262c72a18898c1242e1ca6f4255d4532669903596f194Set In Private M...2271162021-08-31 7:48:10394 days 12 hrs agoGMX: Deployer IN  0x321f653eed006ad1c29d174e17d96351bde226490 ETH0.000907686699 ETH
0xb78ca9ce3b4dbf664aaea234c4a447cba3fdf2979de436e20846a4d16cbeba7c0x608060402271152021-08-31 7:45:58394 days 12 hrs agoGMX: Deployer IN  Create: GlpManager0 ETH0.07193015215 ETH
[ Download CSV Export 
Latest 25 internal transaction
Parent Txn Hash Block From To Value
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x45096e7aa921f27590f8f19e457794eb096781410 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x4277f8f2c384827b5273592ff7cebd9f2c1ac2580 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x45096e7aa921f27590f8f19e457794eb096781410 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x4277f8f2c384827b5273592ff7cebd9f2c1ac2580 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
0xe5ac9a5bca33d39210886a09050aa22e44ae7b414bd2d03212483724aef70d97274796572022-09-29 20:29:091 min ago 0x321f653eed006ad1c29d174e17d96351bde22649 0x489ee077994b6658eafa855c308275ead8097c4a0 ETH
[ Download CSV Export 
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
GlpManager

Compiler Version
v0.6.12+commit.27d51765

Optimization Enabled:
Yes with 1 runs

Other Settings:
default evmVersion, MIT license

Contract Source Code (Solidity)

/**
 *Submitted for verification at Arbiscan on 2021-08-31
*/

// Sources flattened with hardhat v2.6.1 https://hardhat.org

// File contracts/libraries/math/SafeMath.sol

// SPDX-License-Identifier: MIT

pragma solidity 0.6.12;

/**
 * @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;
    }
}


// File contracts/libraries/token/IERC20.sol


pragma solidity 0.6.12;

/**
 * @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);
}


// File contracts/libraries/utils/Address.sol


pragma solidity ^0.6.2;

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize, which returns 0 for contracts in
        // construction, since the code is only stored at the end of the
        // constructor execution.

        uint256 size;
        // 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");
        require(isContract(target), "Address: call to non-contract");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = target.call{ value: value }(data);
        return _verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
        return functionStaticCall(target, data, "Address: low-level static call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(address target, bytes memory data, string memory errorMessage) internal view returns (bytes memory) {
        require(isContract(target), "Address: static call to non-contract");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = target.staticcall(data);
        return _verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.3._
     */
    function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionDelegateCall(target, data, "Address: low-level delegate call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.3._
     */
    function functionDelegateCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) {
        require(isContract(target), "Address: delegate call to non-contract");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = target.delegatecall(data);
        return _verifyCallResult(success, returndata, errorMessage);
    }

    function _verifyCallResult(bool success, bytes memory returndata, string memory errorMessage) private pure returns(bytes memory) {
        if (success) {
            return returndata;
        } else {
            // Look for revert reason and bubble it up if present
            if (returndata.length > 0) {
                // The easiest way to bubble the revert reason is using memory via assembly

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


// File contracts/libraries/token/SafeERC20.sol


pragma solidity 0.6.12;



/**
 * @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");
        }
    }
}


// File contracts/libraries/utils/ReentrancyGuard.sol


pragma solidity 0.6.12;

/**
 * @dev Contract module that helps prevent reentrant calls to a function.
 *
 * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier
 * available, which can be applied to functions to make sure there are no nested
 * (reentrant) calls to them.
 *
 * Note that because there is a single `nonReentrant` guard, functions marked as
 * `nonReentrant` may not call one another. This can be worked around by making
 * those functions `private`, and then adding `external` `nonReentrant` entry
 * points to them.
 *
 * TIP: If you would like to learn more about reentrancy and alternative ways
 * to protect against it, check out our blog post
 * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].
 */
contract ReentrancyGuard {
    // Booleans are more expensive than uint256 or any type that takes up a full
    // word because each write operation emits an extra SLOAD to first read the
    // slot's contents, replace the bits taken up by the boolean, and then write
    // back. This is the compiler's defense against contract upgrades and
    // pointer aliasing, and it cannot be disabled.

    // The values being non-zero value makes deployment a bit more expensive,
    // but in exchange the refund on every call to nonReentrant will be lower in
    // amount. Since refunds are capped to a percentage of the total
    // transaction's gas, it is best to keep them low in cases like this one, to
    // increase the likelihood of the full refund coming into effect.
    uint256 private constant _NOT_ENTERED = 1;
    uint256 private constant _ENTERED = 2;

    uint256 private _status;

    constructor () internal {
        _status = _NOT_ENTERED;
    }

    /**
     * @dev Prevents a contract from calling itself, directly or indirectly.
     * Calling a `nonReentrant` function from another `nonReentrant`
     * function is not supported. It is possible to prevent this from happening
     * by making the `nonReentrant` function external, and make it call a
     * `private` function that does the actual work.
     */
    modifier nonReentrant() {
        // On the first call to nonReentrant, _notEntered will be true
        require(_status != _ENTERED, "ReentrancyGuard: reentrant call");

        // Any calls to nonReentrant after this point will fail
        _status = _ENTERED;

        _;

        // By storing the original value once again, a refund is triggered (see
        // https://eips.ethereum.org/EIPS/eip-2200)
        _status = _NOT_ENTERED;
    }
}


// File contracts/core/interfaces/IVault.sol


pragma solidity 0.6.12;

interface IVault {
    function isInitialized() external view returns (bool);
    function isSwapEnabled() external view returns (bool);
    function isLeverageEnabled() external view returns (bool);

    function setError(uint256 _errorCode, string calldata _error) external;

    function router() external view returns (address);
    function usdg() external view returns (address);
    function gov() external view returns (address);

    function whitelistedTokenCount() external view returns (uint256);
    function maxLeverage() external view returns (uint256);

    function minProfitTime() external view returns (uint256);
    function hasDynamicFees() external view returns (bool);
    function fundingInterval() external view returns (uint256);
    function totalTokenWeights() external view returns (uint256);

    function inManagerMode() external view returns (bool);
    function inPrivateLiquidationMode() external view returns (bool);

    function maxGasPrice() external view returns (uint256);

    function approvedRouters(address _account, address _router) external view returns (bool);
    function isLiquidator(address _account) external view returns (bool);
    function isManager(address _account) external view returns (bool);

    function minProfitBasisPoints(address _token) external view returns (uint256);
    function tokenBalances(address _token) external view returns (uint256);
    function lastFundingTimes(address _token) external view returns (uint256);

    function setInManagerMode(bool _inManagerMode) external;
    function setManager(address _manager, bool _isManager) external;
    function setIsSwapEnabled(bool _isSwapEnabled) external;
    function setIsLeverageEnabled(bool _isLeverageEnabled) external;
    function setMaxGasPrice(uint256 _maxGasPrice) external;

    function setFees(
        uint256 _taxBasisPoints,
        uint256 _stableTaxBasisPoints,
        uint256 _mintBurnFeeBasisPoints,
        uint256 _swapFeeBasisPoints,
        uint256 _stableSwapFeeBasisPoints,
        uint256 _marginFeeBasisPoints,
        uint256 _liquidationFeeUsd,
        uint256 _minProfitTime,
        bool _hasDynamicFees
    ) external;

    function setTokenConfig(
        address _token,
        uint256 _tokenDecimals,
        uint256 _redemptionBps,
        uint256 _minProfitBps,
        uint256 _maxUsdgAmount,
        bool _isStable,
        bool _isShortable
    ) external;

    function setPriceFeed(address _priceFeed) external;
    function withdrawFees(address _token, address _receiver) external returns (uint256);

    function directPoolDeposit(address _token) external;
    function buyUSDG(address _token, address _receiver) external returns (uint256);
    function sellUSDG(address _token, address _receiver) external returns (uint256);
    function swap(address _tokenIn, address _tokenOut, address _receiver) external returns (uint256);
    function increasePosition(address _account, address _collateralToken, address _indexToken, uint256 _sizeDelta, bool _isLong) external;
    function decreasePosition(address _account, address _collateralToken, address _indexToken, uint256 _collateralDelta, uint256 _sizeDelta, bool _isLong, address _receiver) external returns (uint256);
    function tokenToUsdMin(address _token, uint256 _tokenAmount) external view returns (uint256);

    function priceFeed() external view returns (address);
    function fundingRateFactor() external view returns (uint256);
    function stableFundingRateFactor() external view returns (uint256);
    function cumulativeFundingRates(address _token) external view returns (uint256);
    function getNextFundingRate(address _token) external view returns (uint256);
    function getFeeBasisPoints(address _token, uint256 _usdgDelta, uint256 _feeBasisPoints, uint256 _taxBasisPoints, bool _increment) external view returns (uint256);

    function liquidationFeeUsd() external view returns (uint256);
    function taxBasisPoints() external view returns (uint256);
    function stableTaxBasisPoints() external view returns (uint256);
    function mintBurnFeeBasisPoints() external view returns (uint256);
    function swapFeeBasisPoints() external view returns (uint256);
    function stableSwapFeeBasisPoints() external view returns (uint256);
    function marginFeeBasisPoints() external view returns (uint256);

    function allWhitelistedTokensLength() external view returns (uint256);
    function allWhitelistedTokens(uint256) external view returns (address);
    function whitelistedTokens(address _token) external view returns (bool);
    function stableTokens(address _token) external view returns (bool);
    function shortableTokens(address _token) external view returns (bool);
    function feeReserves(address _token) external view returns (uint256);
    function globalShortSizes(address _token) external view returns (uint256);
    function globalShortAveragePrices(address _token) external view returns (uint256);
    function tokenDecimals(address _token) external view returns (uint256);
    function tokenWeights(address _token) external view returns (uint256);
    function guaranteedUsd(address _token) external view returns (uint256);
    function poolAmounts(address _token) external view returns (uint256);
    function bufferAmounts(address _token) external view returns (uint256);
    function reservedAmounts(address _token) external view returns (uint256);
    function usdgAmounts(address _token) external view returns (uint256);
    function maxUsdgAmounts(address _token) external view returns (uint256);
    function getRedemptionAmount(address _token, uint256 _usdgAmount) external view returns (uint256);
    function getMaxPrice(address _token) external view returns (uint256);
    function getMinPrice(address _token) external view returns (uint256);

    function getDelta(address _indexToken, uint256 _size, uint256 _averagePrice, bool _isLong, uint256 _lastIncreasedTime) external view returns (bool, uint256);
    function getPosition(address _account, address _collateralToken, address _indexToken, bool _isLong) external view returns (uint256, uint256, uint256, uint256, uint256, uint256, bool, uint256);
}


// File contracts/core/interfaces/IGlpManager.sol


pragma solidity 0.6.12;

interface IGlpManager {
    function addLiquidity(address _token, uint256 _amount, uint256 _minUsdg, uint256 _minGlp) external returns (uint256);
    function addLiquidityForAccount(address _fundingAccount, address _account, address _token, uint256 _amount, uint256 _minUsdg, uint256 _minGlp) external returns (uint256);
    function removeLiquidity(address _tokenOut, uint256 _glpAmount, uint256 _minOut, address _receiver) external returns (uint256);
    function removeLiquidityForAccount(address _account, address _tokenOut, uint256 _glpAmount, uint256 _minOut, address _receiver) external returns (uint256);
}


// File contracts/tokens/interfaces/IUSDG.sol


pragma solidity 0.6.12;

interface IUSDG {
    function mint(address _account, uint256 _amount) external;
    function burn(address _account, uint256 _amount) external;
}


// File contracts/tokens/interfaces/IMintable.sol


pragma solidity 0.6.12;

interface IMintable {
    function mint(address _account, uint256 _amount) external;
    function burn(address _account, uint256 _amount) external;
}


// File contracts/access/Governable.sol


pragma solidity 0.6.12;

contract Governable {
    address public gov;

    constructor() public {
        gov = msg.sender;
    }

    modifier onlyGov() {
        require(msg.sender == gov, "Governable: forbidden");
        _;
    }

    function setGov(address _gov) external onlyGov {
        gov = _gov;
    }
}


// File contracts/core/GlpManager.sol









pragma solidity 0.6.12;

contract GlpManager is ReentrancyGuard, Governable, IGlpManager {
    using SafeMath for uint256;
    using SafeERC20 for IERC20;

    uint256 public constant PRICE_PRECISION = 10 ** 30;
    uint256 public constant USDG_DECIMALS = 18;
    uint256 public constant MAX_COOLDOWN_DURATION = 48 hours;

    IVault public vault;
    address public usdg;
    address public glp;

    uint256 public cooldownDuration;
    mapping (address => uint256) public lastAddedAt;

    uint256 public aumAddition;
    uint256 public aumDeduction;

    bool public inPrivateMode;
    mapping (address => bool) public isHandler;

    event AddLiquidity(
        address account,
        address token,
        uint256 amount,
        uint256 aumInUsdg,
        uint256 glpSupply,
        uint256 usdgAmount,
        uint256 mintAmount
    );

    event RemoveLiquidity(
        address account,
        address token,
        uint256 glpAmount,
        uint256 aumInUsdg,
        uint256 glpSupply,
        uint256 usdgAmount,
        uint256 amountOut
    );

    constructor(address _vault, address _usdg, address _glp, uint256 _cooldownDuration) public {
        gov = msg.sender;
        vault = IVault(_vault);
        usdg = _usdg;
        glp = _glp;
        cooldownDuration = _cooldownDuration;
    }

    function setInPrivateMode(bool _inPrivateMode) external onlyGov {
        inPrivateMode = _inPrivateMode;
    }

    function setHandler(address _handler, bool _isActive) external onlyGov {
        isHandler[_handler] = _isActive;
    }

    function setCooldownDuration(uint256 _cooldownDuration) external onlyGov {
        require(_cooldownDuration <= MAX_COOLDOWN_DURATION, "GlpManager: invalid _cooldownDuration");
        cooldownDuration = _cooldownDuration;
    }

    function setAumAdjustment(uint256 _aumAddition, uint256 _aumDeduction) external onlyGov {
        aumAddition = _aumAddition;
        aumDeduction = _aumDeduction;
    }

    function addLiquidity(address _token, uint256 _amount, uint256 _minUsdg, uint256 _minGlp) external override nonReentrant returns (uint256) {
        if (inPrivateMode) { revert("GlpManager: action not enabled"); }
        return _addLiquidity(msg.sender, msg.sender, _token, _amount, _minUsdg, _minGlp);
    }

    function addLiquidityForAccount(address _fundingAccount, address _account, address _token, uint256 _amount, uint256 _minUsdg, uint256 _minGlp) external override nonReentrant returns (uint256) {
        _validateHandler();
        return _addLiquidity(_fundingAccount, _account, _token, _amount, _minUsdg, _minGlp);
    }

    function removeLiquidity(address _tokenOut, uint256 _glpAmount, uint256 _minOut, address _receiver) external override nonReentrant returns (uint256) {
        if (inPrivateMode) { revert("GlpManager: action not enabled"); }
        return _removeLiquidity(msg.sender, _tokenOut, _glpAmount, _minOut, _receiver);
    }

    function removeLiquidityForAccount(address _account, address _tokenOut, uint256 _glpAmount, uint256 _minOut, address _receiver) external override nonReentrant returns (uint256) {
        _validateHandler();
        return _removeLiquidity(_account, _tokenOut, _glpAmount, _minOut, _receiver);
    }

    function getAums() public view returns (uint256[] memory) {
        uint256[] memory amounts = new uint256[](2);
        amounts[0] = getAum(true);
        amounts[1] = getAum(false);
        return amounts;
    }

    function getAumInUsdg(bool maximise) public view returns (uint256) {
        uint256 aum = getAum(maximise);
        return aum.mul(10 ** USDG_DECIMALS).div(PRICE_PRECISION);
    }

    function getAum(bool maximise) public view returns (uint256) {
        uint256 length = vault.allWhitelistedTokensLength();
        uint256 aum = aumAddition;
        uint256 shortProfits = 0;

        for (uint256 i = 0; i < length; i++) {
            address token = vault.allWhitelistedTokens(i);
            bool isWhitelisted = vault.whitelistedTokens(token);

            if (!isWhitelisted) {
                continue;
            }

            uint256 price = maximise ? vault.getMaxPrice(token) : vault.getMinPrice(token);
            uint256 poolAmount = vault.poolAmounts(token);
            uint256 decimals = vault.tokenDecimals(token);

            if (vault.stableTokens(token)) {
                aum = aum.add(poolAmount.mul(price).div(10 ** decimals));
            } else {
                // add global short profit / loss
                uint256 size = vault.globalShortSizes(token);
                if (size > 0) {
                    uint256 averagePrice = vault.globalShortAveragePrices(token);
                    uint256 priceDelta = averagePrice > price ? averagePrice.sub(price) : price.sub(averagePrice);
                    uint256 delta = size.mul(priceDelta).div(averagePrice);
                    if (price > averagePrice) {
                        // add losses from shorts
                        aum = aum.add(delta);
                    } else {
                        shortProfits = shortProfits.add(delta);
                    }
                }

                aum = aum.add(vault.guaranteedUsd(token));

                uint256 reservedAmount = vault.reservedAmounts(token);
                aum = aum.add(poolAmount.sub(reservedAmount).mul(price).div(10 ** decimals));
            }
        }

        aum = shortProfits > aum ? 0 : aum.sub(shortProfits);
        return aumDeduction > aum ? 0 : aum.sub(aumDeduction);
    }

    function _addLiquidity(address _fundingAccount, address _account, address _token, uint256 _amount, uint256 _minUsdg, uint256 _minGlp) private returns (uint256) {
        require(_amount > 0, "GlpManager: invalid _amount");

        // calculate aum before buyUSDG
        uint256 aumInUsdg = getAumInUsdg(true);
        uint256 glpSupply = IERC20(glp).totalSupply();

        IERC20(_token).safeTransferFrom(_fundingAccount, address(vault), _amount);
        uint256 usdgAmount = vault.buyUSDG(_token, address(this));
        require(usdgAmount >= _minUsdg, "GlpManager: insufficient USDG output");

        uint256 mintAmount = aumInUsdg == 0 ? usdgAmount : usdgAmount.mul(glpSupply).div(aumInUsdg);
        require(mintAmount >= _minGlp, "GlpManager: insufficient GLP output");

        IMintable(glp).mint(_account, mintAmount);

        lastAddedAt[_account] = block.timestamp;

        emit AddLiquidity(_account, _token, _amount, aumInUsdg, glpSupply, usdgAmount, mintAmount);

        return mintAmount;
    }

    function _removeLiquidity(address _account, address _tokenOut, uint256 _glpAmount, uint256 _minOut, address _receiver) private returns (uint256) {
        require(_glpAmount > 0, "GlpManager: invalid _glpAmount");
        require(lastAddedAt[_account].add(cooldownDuration) <= block.timestamp, "GlpManager: cooldown duration not yet passed");

        // calculate aum before sellUSDG
        uint256 aumInUsdg = getAumInUsdg(false);
        uint256 glpSupply = IERC20(glp).totalSupply();

        uint256 usdgAmount = _glpAmount.mul(aumInUsdg).div(glpSupply);
        uint256 usdgBalance = IERC20(usdg).balanceOf(address(this));
        if (usdgAmount > usdgBalance) {
            IUSDG(usdg).mint(address(this), usdgAmount.sub(usdgBalance));
        }

        IMintable(glp).burn(_account, _glpAmount);

        IERC20(usdg).transfer(address(vault), usdgAmount);
        uint256 amountOut = vault.sellUSDG(_tokenOut, _receiver);
        require(amountOut >= _minOut, "GlpManager: insufficient output");

        emit RemoveLiquidity(_account, _tokenOut, _glpAmount, aumInUsdg, glpSupply, usdgAmount, amountOut);

        return amountOut;
    }

    function _validateHandler() private view {
        require(isHandler[msg.sender], "GlpManager: forbidden");
    }
}

Contract ABI

[{"inputs":[{"internalType":"address","name":"_vault","type":"address"},{"internalType":"address","name":"_usdg","type":"address"},{"internalType":"address","name":"_glp","type":"address"},{"internalType":"uint256","name":"_cooldownDuration","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"aumInUsdg","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"glpSupply","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"usdgAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"mintAmount","type":"uint256"}],"name":"AddLiquidity","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"glpAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"aumInUsdg","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"glpSupply","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"usdgAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amountOut","type":"uint256"}],"name":"RemoveLiquidity","type":"event"},{"inputs":[],"name":"MAX_COOLDOWN_DURATION","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"PRICE_PRECISION","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"USDG_DECIMALS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"uint256","name":"_minUsdg","type":"uint256"},{"internalType":"uint256","name":"_minGlp","type":"uint256"}],"name":"addLiquidity","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_fundingAccount","type":"address"},{"internalType":"address","name":"_account","type":"address"},{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"uint256","name":"_minUsdg","type":"uint256"},{"internalType":"uint256","name":"_minGlp","type":"uint256"}],"name":"addLiquidityForAccount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"aumAddition","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"aumDeduction","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"cooldownDuration","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"maximise","type":"bool"}],"name":"getAum","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"maximise","type":"bool"}],"name":"getAumInUsdg","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAums","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"glp","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"gov","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"inPrivateMode","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"isHandler","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"lastAddedAt","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_tokenOut","type":"address"},{"internalType":"uint256","name":"_glpAmount","type":"uint256"},{"internalType":"uint256","name":"_minOut","type":"uint256"},{"internalType":"address","name":"_receiver","type":"address"}],"name":"removeLiquidity","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"address","name":"_tokenOut","type":"address"},{"internalType":"uint256","name":"_glpAmount","type":"uint256"},{"internalType":"uint256","name":"_minOut","type":"uint256"},{"internalType":"address","name":"_receiver","type":"address"}],"name":"removeLiquidityForAccount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_aumAddition","type":"uint256"},{"internalType":"uint256","name":"_aumDeduction","type":"uint256"}],"name":"setAumAdjustment","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_cooldownDuration","type":"uint256"}],"name":"setCooldownDuration","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_gov","type":"address"}],"name":"setGov","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_handler","type":"address"},{"internalType":"bool","name":"_isActive","type":"bool"}],"name":"setHandler","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_inPrivateMode","type":"bool"}],"name":"setInPrivateMode","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"usdg","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"vault","outputs":[{"internalType":"contract IVault","name":"","type":"address"}],"stateMutability":"view","type":"function"}]

608060405234801561001057600080fd5b506040516120c03803806120c08339818101604052608081101561003357600080fd5b50805160208201516040830151606090930151600160008181558154336001600160a01b031991821681178216179092556002805483166001600160a01b03968716179055600380548316948616949094179093556004805490911693909416929092179092556005556120139081906100ad90396000f3fe608060405234801561001057600080fd5b50600436106101335760003560e01c80630339147614610138578063070eacee1461016957806312d43a511461018557806317eb2a15146101a9578063196b68cb146101f15780631e9049cf146101f95780631ece366a14610201578063352693151461023957806346ea87af1461024157806368a0a3e0146102675780636a86da191461028657806371d597ad146102a757806378a207ee146102eb578063870d917c146102f35780638b770e11146102fb5780638fed0b2c146103215780639116c4ae1461035b57806395082d251461037e578063966be075146103865780639cb7de4b146103a3578063b172bb0c146103d1578063cfad57a2146103d9578063ed0d1c04146103ff578063f5b91b7b14610457578063fbfa77cf1461045f575b600080fd5b6101576004803603602081101561014e57600080fd5b50351515610467565b60408051918252519081900360200190f35b610171610b88565b604080519115158252519081900360200190f35b61018d610b91565b604080516001600160a01b039092168252519081900360200190f35b610157600480360360c08110156101bf57600080fd5b506001600160a01b03813581169160208101358216916040820135169060608101359060808101359060a00135610ba0565b610157610c13565b610157610c19565b6101576004803603608081101561021757600080fd5b506001600160a01b038135169060208101359060408101359060600135610c20565b610157610ccf565b6101716004803603602081101561025757600080fd5b50356001600160a01b0316610cd5565b6101576004803603602081101561027d57600080fd5b50351515610cea565b6102a56004803603602081101561029c57600080fd5b50351515610d21565b005b610157600480360360a08110156102bd57600080fd5b506001600160a01b038135811691602081013582169160408201359160608101359160809091013516610d81565b61018d610df2565b610157610e01565b6101576004803603602081101561031157600080fd5b50356001600160a01b0316610e06565b6101576004803603608081101561033757600080fd5b506001600160a01b0381358116916020810135916040820135916060013516610e18565b6102a56004803603604081101561037157600080fd5b5080359060200135610eb8565b610157610f10565b6102a56004803603602081101561039c57600080fd5b5035610f20565b6102a5600480360360408110156103b957600080fd5b506001600160a01b0381351690602001351515610fb4565b61015761102c565b6102a5600480360360208110156103ef57600080fd5b50356001600160a01b0316611032565b6104076110a1565b60408051602080825283518183015283519192839290830191858101910280838360005b8381101561044357818101518382015260200161042b565b505050509050019250505060405180910390f35b61018d61110f565b61018d61111e565b600080600260009054906101000a90046001600160a01b03166001600160a01b0316630842b0766040518163ffffffff1660e01b815260040160206040518083038186803b1580156104b857600080fd5b505afa1580156104cc573d6000803e3d6000fd5b505050506040513d60208110156104e257600080fd5b50516007549091506000805b83811015610b445760025460408051630e468baf60e41b81526004810184905290516000926001600160a01b03169163e468baf0916024808301926020929190829003018186803b15801561054257600080fd5b505afa158015610556573d6000803e3d6000fd5b505050506040513d602081101561056c57600080fd5b505160025460408051630daf9c2160e41b81526001600160a01b0380851660048301529151939450600093919092169163daf9c210916024808301926020929190829003018186803b1580156105c157600080fd5b505afa1580156105d5573d6000803e3d6000fd5b505050506040513d60208110156105eb57600080fd5b50519050806105fb575050610b3c565b60008861068057600254604080516340d3096b60e11b81526001600160a01b038681166004830152915191909216916381a612d6916024808301926020929190829003018186803b15801561064f57600080fd5b505afa158015610663573d6000803e3d6000fd5b505050506040513d602081101561067957600080fd5b50516106fa565b60025460408051637092736960e11b81526001600160a01b0386811660048301529151919092169163e124e6d2916024808301926020929190829003018186803b1580156106cd57600080fd5b505afa1580156106e1573d6000803e3d6000fd5b505050506040513d60208110156106f757600080fd5b50515b600254604080516352f55eed60e01b81526001600160a01b038781166004830152915193945060009391909216916352f55eed916024808301926020929190829003018186803b15801561074d57600080fd5b505afa158015610761573d6000803e3d6000fd5b505050506040513d602081101561077757600080fd5b5051600254604080516323b95ceb60e21b81526001600160a01b03888116600483015291519394506000939190921691638ee573ac916024808301926020929190829003018186803b1580156107cc57600080fd5b505afa1580156107e0573d6000803e3d6000fd5b505050506040513d60208110156107f657600080fd5b5051600254604080516342b60b0360e01b81526001600160a01b03898116600483015291519394509116916342b60b0391602480820192602092909190829003018186803b15801561084757600080fd5b505afa15801561085b573d6000803e3d6000fd5b505050506040513d602081101561087157600080fd5b5051156108a15761089a610893600a83900a61088d858761112d565b9061118f565b89906111ce565b9750610b36565b6002546040805163114f1b5560e31b81526001600160a01b03888116600483015291516000939290921691638a78daa891602480820192602092909190829003018186803b1580156108f257600080fd5b505afa158015610906573d6000803e3d6000fd5b505050506040513d602081101561091c57600080fd5b505190508015610a055760025460408051636274980360e01b81526001600160a01b03898116600483015291516000939290921691636274980391602480820192602092909190829003018186803b15801561097757600080fd5b505afa15801561098b573d6000803e3d6000fd5b505050506040513d60208110156109a157600080fd5b5051905060008582116109bd576109b88683611226565b6109c7565b6109c78287611226565b905060006109d98361088d868561112d565b9050828711156109f4576109ed8c826111ce565b9b50610a01565b6109fe8b826111ce565b9a505b5050505b6002546040805163783a2b6760e11b81526001600160a01b0389811660048301529151610a8a93929092169163f07456ce91602480820192602092909190829003018186803b158015610a5757600080fd5b505afa158015610a6b573d6000803e3d6000fd5b505050506040513d6020811015610a8157600080fd5b50518a906111ce565b6002546040805163c3c7b9e960e01b81526001600160a01b038a811660048301529151939c50600093919092169163c3c7b9e9916024808301926020929190829003018186803b158015610add57600080fd5b505afa158015610af1573d6000803e3d6000fd5b505050506040513d6020811015610b0757600080fd5b50519050610b31610b2a600a85900a61088d88610b248987611226565b9061112d565b8b906111ce565b995050505b50505050505b6001016104ee565b50818111610b5b57610b568282611226565b610b5e565b60005b91508160085411610b7c57600854610b77908390611226565b610b7f565b60005b95945050505050565b60095460ff1681565b6001546001600160a01b031681565b600060026000541415610be8576040805162461bcd60e51b815260206004820152601f6024820152600080516020611e9a833981519152604482015290519081900360640190fd5b6002600055610bf5611268565b610c038787878787876112c6565b6001600055979650505050505050565b60075481565b6202a30081565b600060026000541415610c68576040805162461bcd60e51b815260206004820152601f6024820152600080516020611e9a833981519152604482015290519081900360640190fd5b600260005560095460ff1615610cb3576040805162461bcd60e51b815260206004820152601e6024820152600080516020611f00833981519152604482015290519081900360640190fd5b610cc13333878787876112c6565b600160005595945050505050565b60055481565b600a6020526000908152604090205460ff1681565b600080610cf683610467565b9050610d1a68327cb2734119d3b7a9601e1b61088d83670de0b6b3a764000061112d565b9392505050565b6001546001600160a01b03163314610d6e576040805162461bcd60e51b81526020600482015260156024820152600080516020611eba833981519152604482015290519081900360640190fd5b6009805460ff1916911515919091179055565b600060026000541415610dc9576040805162461bcd60e51b815260206004820152601f6024820152600080516020611e9a833981519152604482015290519081900360640190fd5b6002600055610dd6611268565b610de386868686866115e3565b60016000559695505050505050565b6004546001600160a01b031681565b601281565b60066020526000908152604090205481565b600060026000541415610e60576040805162461bcd60e51b815260206004820152601f6024820152600080516020611e9a833981519152604482015290519081900360640190fd5b600260005560095460ff1615610eab576040805162461bcd60e51b815260206004820152601e6024820152600080516020611f00833981519152604482015290519081900360640190fd5b610cc133868686866115e3565b6001546001600160a01b03163314610f05576040805162461bcd60e51b81526020600482015260156024820152600080516020611eba833981519152604482015290519081900360640190fd5b600791909155600855565b68327cb2734119d3b7a9601e1b81565b6001546001600160a01b03163314610f6d576040805162461bcd60e51b81526020600482015260156024820152600080516020611eba833981519152604482015290519081900360640190fd5b6202a300811115610faf5760405162461bcd60e51b8152600401808060200182810382526025815260200180611e756025913960400191505060405180910390fd5b600555565b6001546001600160a01b03163314611001576040805162461bcd60e51b81526020600482015260156024820152600080516020611eba833981519152604482015290519081900360640190fd5b6001600160a01b03919091166000908152600a60205260409020805460ff1916911515919091179055565b60085481565b6001546001600160a01b0316331461107f576040805162461bcd60e51b81526020600482015260156024820152600080516020611eba833981519152604482015290519081900360640190fd5b600180546001600160a01b0319166001600160a01b0392909216919091179055565b6040805160028082526060808301845292839291906020830190803683370190505090506110cf6001610467565b816000815181106110dc57fe5b6020026020010181815250506110f26000610467565b816001815181106110ff57fe5b6020908102919091010152905090565b6003546001600160a01b031681565b6002546001600160a01b031681565b60008261113c57506000611189565b8282028284828161114957fe5b04146111865760405162461bcd60e51b8152600401808060200182810382526021815260200180611f4c6021913960400191505060405180910390fd5b90505b92915050565b600061118683836040518060400160405280601a815260200179536166654d6174683a206469766973696f6e206279207a65726f60301b815250611a83565b600082820183811015611186576040805162461bcd60e51b815260206004820152601b60248201527a536166654d6174683a206164646974696f6e206f766572666c6f7760281b604482015290519081900360640190fd5b600061118683836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250611b25565b336000908152600a602052604090205460ff166112c4576040805162461bcd60e51b815260206004820152601560248201527423b63826b0b730b3b2b91d103337b93134b23232b760591b604482015290519081900360640190fd5b565b600080841161131a576040805162461bcd60e51b815260206004820152601b60248201527a11db1c13585b9859d95c8e881a5b9d985b1a590817d85b5bdd5b9d602a1b604482015290519081900360640190fd5b60006113266001610cea565b90506000600460009054906101000a90046001600160a01b03166001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561137857600080fd5b505afa15801561138c573d6000803e3d6000fd5b505050506040513d60208110156113a257600080fd5b50516002549091506113c3906001600160a01b03898116918c911689611b7f565b6002546040805163817bb85760e01b81526001600160a01b038a811660048301523060248301529151600093929092169163817bb8579160448082019260209290919082900301818787803b15801561141b57600080fd5b505af115801561142f573d6000803e3d6000fd5b505050506040513d602081101561144557600080fd5b50519050858110156114885760405162461bcd60e51b8152600401808060200182810382526024815260200180611f906024913960400191505060405180910390fd5b600083156114a35761149e8461088d848661112d565b6114a5565b815b9050858110156114e65760405162461bcd60e51b8152600401808060200182810382526023815260200180611f6d6023913960400191505060405180910390fd5b60048054604080516340c10f1960e01b81526001600160a01b038e81169482019490945260248101859052905192909116916340c10f199160448082019260009290919082900301818387803b15801561153f57600080fd5b505af1158015611553573d6000803e3d6000fd5b5050506001600160a01b03808c166000818152600660209081526040918290204290558151928352928d16928201929092528082018b9052606081018790526080810186905260a0810185905260c0810184905290517f38dc38b96482be64113daffd8d464ebda93e856b70ccfc605e69ccf892ab981e92509081900360e00190a19a9950505050505050505050565b6000808411611639576040805162461bcd60e51b815260206004820152601e60248201527f476c704d616e616765723a20696e76616c6964205f676c70416d6f756e740000604482015290519081900360640190fd5b6005546001600160a01b038716600090815260066020526040902054429161166191906111ce565b111561169e5760405162461bcd60e51b815260040180806020018281038252602c815260200180611f20602c913960400191505060405180910390fd5b60006116aa6000610cea565b90506000600460009054906101000a90046001600160a01b03166001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b1580156116fc57600080fd5b505afa158015611710573d6000803e3d6000fd5b505050506040513d602081101561172657600080fd5b50519050600061173a8261088d898661112d565b600354604080516370a0823160e01b815230600482015290519293506000926001600160a01b03909216916370a0823191602480820192602092909190829003018186803b15801561178b57600080fd5b505afa15801561179f573d6000803e3d6000fd5b505050506040513d60208110156117b557600080fd5b505190508082111561183c576003546001600160a01b03166340c10f19306117dd8585611226565b6040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050600060405180830381600087803b15801561182357600080fd5b505af1158015611837573d6000803e3d6000fd5b505050505b6004805460408051632770a7eb60e21b81526001600160a01b038e811694820194909452602481018c905290519290911691639dc29fac9160448082019260009290919082900301818387803b15801561189557600080fd5b505af11580156118a9573d6000803e3d6000fd5b50506003546002546040805163a9059cbb60e01b81526001600160a01b03928316600482015260248101889052905191909216935063a9059cbb925060448083019260209291908290030181600087803b15801561190657600080fd5b505af115801561191a573d6000803e3d6000fd5b505050506040513d602081101561193057600080fd5b505060025460408051630711e61960e41b81526001600160a01b038c8116600483015289811660248301529151600093929092169163711e61909160448082019260209290919082900301818787803b15801561198c57600080fd5b505af11580156119a0573d6000803e3d6000fd5b505050506040513d60208110156119b657600080fd5b5051905087811015611a0f576040805162461bcd60e51b815260206004820152601f60248201527f476c704d616e616765723a20696e73756666696369656e74206f757470757400604482015290519081900360640190fd5b604080516001600160a01b03808e1682528c1660208201528082018b9052606081018790526080810186905260a0810185905260c0810183905290517f87b9679bb9a4944bafa98c267e7cd4a00ab29fed48afdefae25f0fca5da279409181900360e00190a19a9950505050505050505050565b60008183611b0f5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b83811015611ad4578181015183820152602001611abc565b50505050905090810190601f168015611b015780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b506000838581611b1b57fe5b0495945050505050565b60008184841115611b775760405162461bcd60e51b8152602060048201818152835160248401528351909283926044909101919085019080838360008315611ad4578181015183820152602001611abc565b505050900390565b604080516001600160a01b0380861660248301528416604482015260648082018490528251808303909101815260849091019091526020810180516001600160e01b03166323b872dd60e01b179052611bd9908590611bdf565b50505050565b6060611c34826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316611c959092919063ffffffff16565b805190915015611c9057808060200190516020811015611c5357600080fd5b5051611c905760405162461bcd60e51b815260040180806020018281038252602a815260200180611fb4602a913960400191505060405180910390fd5b505050565b6060611ca48484600085611cac565b949350505050565b606082471015611ced5760405162461bcd60e51b8152600401808060200182810382526026815260200180611eda6026913960400191505060405180910390fd5b611cf685611e08565b611d47576040805162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015290519081900360640190fd5b60006060866001600160a01b031685876040518082805190602001908083835b60208310611d865780518252601f199092019160209182019101611d67565b6001836020036101000a03801982511681845116808217855250505050505090500191505060006040518083038185875af1925050503d8060008114611de8576040519150601f19603f3d011682016040523d82523d6000602084013e611ded565b606091505b5091509150611dfd828286611e0e565b979650505050505050565b3b151590565b60608315611e1d575081610d1a565b825115611e2d5782518084602001fd5b60405162461bcd60e51b8152602060048201818152845160248401528451859391928392604401919085019080838360008315611ad4578181015183820152602001611abc56fe476c704d616e616765723a20696e76616c6964205f636f6f6c646f776e4475726174696f6e5265656e7472616e637947756172643a207265656e7472616e742063616c6c00476f7665726e61626c653a20666f7262696464656e0000000000000000000000416464726573733a20696e73756666696369656e742062616c616e636520666f722063616c6c476c704d616e616765723a20616374696f6e206e6f7420656e61626c65640000476c704d616e616765723a20636f6f6c646f776e206475726174696f6e206e6f742079657420706173736564536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77476c704d616e616765723a20696e73756666696369656e7420474c50206f7574707574476c704d616e616765723a20696e73756666696369656e742055534447206f75747075745361666545524332303a204552433230206f7065726174696f6e20646964206e6f742073756363656564a2646970667358221220c95e4ff2832feb7b25d2dc7e7dc18d46d4b152da9ba0434600660091a9a552da64736f6c634300060c0033000000000000000000000000489ee077994b6658eafa855c308275ead8097c4a00000000000000000000000045096e7aa921f27590f8f19e457794eb096781410000000000000000000000004277f8f2c384827b5273592ff7cebd9f2c1ac2580000000000000000000000000000000000000000000000000000000000000384

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

000000000000000000000000489ee077994b6658eafa855c308275ead8097c4a00000000000000000000000045096e7aa921f27590f8f19e457794eb096781410000000000000000000000004277f8f2c384827b5273592ff7cebd9f2c1ac2580000000000000000000000000000000000000000000000000000000000000384

-----Decoded View---------------
Arg [0] : _vault (address): 0x489ee077994b6658eafa855c308275ead8097c4a
Arg [1] : _usdg (address): 0x45096e7aa921f27590f8f19e457794eb09678141
Arg [2] : _glp (address): 0x4277f8f2c384827b5273592ff7cebd9f2c1ac258
Arg [3] : _cooldownDuration (uint256): 900

-----Encoded View---------------
4 Constructor Arguments found :
Arg [0] : 000000000000000000000000489ee077994b6658eafa855c308275ead8097c4a
Arg [1] : 00000000000000000000000045096e7aa921f27590f8f19e457794eb09678141
Arg [2] : 0000000000000000000000004277f8f2c384827b5273592ff7cebd9f2c1ac258
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000384


Deployed ByteCode Sourcemap

30715:7977:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;34433:1910;;;;;;;;;;;;;;;;-1:-1:-1;34433:1910:0;;;;:::i;:::-;;;;;;;;;;;;;;;;31267:25;;;:::i;:::-;;;;;;;;;;;;;;;;;;30346:18;;;:::i;:::-;;;;-1:-1:-1;;;;;30346:18:0;;;;;;;;;;;;;;33048:323;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;33048:323:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;31198:26::-;;;:::i;30960:56::-;;;:::i;32728:312::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;32728:312:0;;;;;;;;;;;;;;;;;;:::i;31104:31::-;;;:::i;31299:42::-;;;;;;;;;;;;;;;;-1:-1:-1;31299:42:0;-1:-1:-1;;;;;31299:42:0;;:::i;34242:183::-;;;;;;;;;;;;;;;;-1:-1:-1;34242:183:0;;;;:::i;32059:113::-;;;;;;;;;;;;;;;;-1:-1:-1;32059:113:0;;;;:::i;:::-;;33707:301;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;33707:301:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;31077:18::-;;;:::i;30911:42::-;;;:::i;31142:47::-;;;;;;;;;;;;;;;;-1:-1:-1;31142:47:0;-1:-1:-1;;;;;31142:47:0;;:::i;33379:320::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;33379:320:0;;;;;;;;;;;;;;;;;;;;:::i;32548:172::-;;;;;;;;;;;;;;;;-1:-1:-1;32548:172:0;;;;;;;:::i;30854:50::-;;;:::i;32309:231::-;;;;;;;;;;;;;;;;-1:-1:-1;32309:231:0;;:::i;32180:121::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;32180:121:0;;;;;;;;;;:::i;31231:27::-;;;:::i;30546:76::-;;;;;;;;;;;;;;;;-1:-1:-1;30546:76:0;-1:-1:-1;;;;;30546:76:0;;:::i;34016:218::-;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;31051:19;;;:::i;31025:::-;;;:::i;34433:1910::-;34485:7;34505:14;34522:5;;;;;;;;;-1:-1:-1;;;;;34522:5:0;-1:-1:-1;;;;;34522:32:0;;:34;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;34522:34:0;34581:11;;34522:34;;-1:-1:-1;34567:11:0;;34640:1567;34664:6;34660:1;:10;34640:1567;;;34708:5;;:29;;;-1:-1:-1;;;34708:29:0;;;;;;;;;;34692:13;;-1:-1:-1;;;;;34708:5:0;;:26;;:29;;;;;;;;;;;;;;:5;:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;34708:29:0;34773:5;;:30;;;-1:-1:-1;;;34773:30:0;;-1:-1:-1;;;;;34773:30:0;;;;;;;;;34708:29;;-1:-1:-1;34752:18:0;;34773:5;;;;;:23;;:30;;;;;34708:29;;34773:30;;;;;;;:5;:30;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;34773:30:0;;-1:-1:-1;34773:30:0;34820:63;;34859:8;;;;34820:63;34899:13;34915:8;:62;;34953:5;;:24;;;-1:-1:-1;;;34953:24:0;;-1:-1:-1;;;;;34953:24:0;;;;;;;;;:5;;;;;:17;;:24;;;;;;;;;;;;;;:5;:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;34953:24:0;34915:62;;;34926:5;;:24;;;-1:-1:-1;;;34926:24:0;;-1:-1:-1;;;;;34926:24:0;;;;;;;;;:5;;;;;:17;;:24;;;;;;;;;;;;;;:5;:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;34926:24:0;34915:62;35013:5;;:24;;;-1:-1:-1;;;35013:24:0;;-1:-1:-1;;;;;35013:24:0;;;;;;;;;34899:78;;-1:-1:-1;34992:18:0;;35013:5;;;;;:17;;:24;;;;;;;;;;;;;;:5;:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;35013:24:0;35071:5;;:26;;;-1:-1:-1;;;35071:26:0;;-1:-1:-1;;;;;35071:26:0;;;;;;;;;35013:24;;-1:-1:-1;35052:16:0;;35071:5;;;;;:19;;:26;;;;;35013:24;;35071:26;;;;;;;:5;:26;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;35071:26:0;35118:5;;:25;;;-1:-1:-1;;;35118:25:0;;-1:-1:-1;;;;;35118:25:0;;;;;;;;;35071:26;;-1:-1:-1;35118:5:0;;;:18;;:25;;;;;35071:26;;35118:25;;;;;;;;:5;:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;35118:25:0;35114:1082;;;35170:50;35178:41;35204:2;:14;;;35178:21;:10;35193:5;35178:14;:21::i;:::-;:25;;:41::i;:::-;35170:3;;:7;:50::i;:::-;35164:56;;35114:1082;;;35327:5;;:29;;;-1:-1:-1;;;35327:29:0;;-1:-1:-1;;;;;35327:29:0;;;;;;;;;35312:12;;35327:5;;;;;:22;;:29;;;;;;;;;;;;;;;:5;:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;35327:29:0;;-1:-1:-1;35379:8:0;;35375:575;;35435:5;;:37;;;-1:-1:-1;;;35435:37:0;;-1:-1:-1;;;;;35435:37:0;;;;;;;;;35412:20;;35435:5;;;;;:30;;:37;;;;;;;;;;;;;;;:5;:37;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;35435:37:0;;-1:-1:-1;35495:18:0;35516:20;;;:72;;35565:23;:5;35575:12;35565:9;:23::i;:::-;35516:72;;;35539:23;:12;35556:5;35539:16;:23::i;:::-;35495:93;-1:-1:-1;35611:13:0;35627:38;35652:12;35627:20;:4;35495:93;35627:8;:20::i;:38::-;35611:54;;35700:12;35692:5;:20;35688:243;;;35798:14;:3;35806:5;35798:7;:14::i;:::-;35792:20;;35688:243;;;35884:23;:12;35901:5;35884:16;:23::i;:::-;35869:38;;35688:243;35375:575;;;;35984:5;;:26;;;-1:-1:-1;;;35984:26:0;;-1:-1:-1;;;;;35984:26:0;;;;;;;;;35976:35;;35984:5;;;;;:19;;:26;;;;;;;;;;;;;;;:5;:26;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;35984:26:0;35976:3;;:7;:35::i;:::-;36057:5;;:28;;;-1:-1:-1;;;36057:28:0;;-1:-1:-1;;;;;36057:28:0;;;;;;;;;35970:41;;-1:-1:-1;36032:22:0;;36057:5;;;;;:21;;:28;;;;;;;;;;;;;;:5;:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;36057:28:0;;-1:-1:-1;36110:70:0;36118:61;36164:2;:14;;;36118:41;36153:5;36118:30;:10;36057:28;36118:14;:30::i;:::-;:34;;:41::i;:61::-;36110:3;;:7;:70::i;:::-;36104:76;;35114:1082;;;34640:1567;;;;;;34672:3;;34640:1567;;;;36240:3;36225:12;:18;:46;;36250:21;:3;36258:12;36250:7;:21::i;:::-;36225:46;;;36246:1;36225:46;36219:52;;36304:3;36289:12;;:18;:46;;36322:12;;36314:21;;:3;;:7;:21::i;:::-;36289:46;;;36310:1;36289:46;36282:53;34433:1910;-1:-1:-1;;;;;34433:1910:0:o;31267:25::-;;;;;;:::o;30346:18::-;;;-1:-1:-1;;;;;30346:18:0;;:::o;33048:323::-;33231:7;21735:1;22341:7;;:19;;22333:63;;;;;-1:-1:-1;;;22333:63:0;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;22333:63:0;;;;;;;;;;;;;;;21735:1;22474:7;:18;33251::::1;:16;:18::i;:::-;33287:76;33301:15;33318:8;33328:6;33336:7;33345:8;33355:7;33287:13;:76::i;:::-;21691:1:::0;22653:7;:22;33280:83;33048:323;-1:-1:-1;;;;;;;33048:323:0:o;31198:26::-;;;;:::o;30960:56::-;31008:8;30960:56;:::o;32728:312::-;32858:7;21735:1;22341:7;;:19;;22333:63;;;;;-1:-1:-1;;;22333:63:0;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;22333:63:0;;;;;;;;;;;;;;;21735:1;22474:7;:18;32882:13:::1;::::0;::::1;;32878:64;;;32899:40;::::0;;-1:-1:-1;;;32899:40:0;;::::1;;::::0;::::1;::::0;::::1;::::0;;;;-1:-1:-1;;;;;;;;;;;32899:40:0;;;;;;;;;;;;;::::1;32878:64;32959:73;32973:10;32985;32997:6;33005:7;33014:8;33024:7;32959:13;:73::i;:::-;21691:1:::0;22653:7;:22;32952:80;32728:312;-1:-1:-1;;;;;32728:312:0:o;31104:31::-;;;;:::o;31299:42::-;;;;;;;;;;;;;;;:::o;34242:183::-;34300:7;34320:11;34334:16;34341:8;34334:6;:16::i;:::-;34320:30;-1:-1:-1;34368:49:0;-1:-1:-1;;;34368:28:0;34320:30;34376:19;34368:7;:28::i;:49::-;34361:56;34242:183;-1:-1:-1;;;34242:183:0:o;32059:113::-;30489:3;;-1:-1:-1;;;;;30489:3:0;30475:10;:17;30467:51;;;;;-1:-1:-1;;;30467:51:0;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;30467:51:0;;;;;;;;;;;;;;;32134:13:::1;:30:::0;;-1:-1:-1;;32134:30:0::1;::::0;::::1;;::::0;;;::::1;::::0;;32059:113::o;33707:301::-;33875:7;21735:1;22341:7;;:19;;22333:63;;;;;-1:-1:-1;;;22333:63:0;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;22333:63:0;;;;;;;;;;;;;;;21735:1;22474:7;:18;33895::::1;:16;:18::i;:::-;33931:69;33948:8;33958:9;33969:10;33981:7;33990:9;33931:16;:69::i;:::-;21691:1:::0;22653:7;:22;33924:76;33707:301;-1:-1:-1;;;;;;33707:301:0:o;31077:18::-;;;-1:-1:-1;;;;;31077:18:0;;:::o;30911:42::-;30951:2;30911:42;:::o;31142:47::-;;;;;;;;;;;;;:::o;33379:320::-;33519:7;21735:1;22341:7;;:19;;22333:63;;;;;-1:-1:-1;;;22333:63:0;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;22333:63:0;;;;;;;;;;;;;;;21735:1;22474:7;:18;33543:13:::1;::::0;::::1;;33539:64;;;33560:40;::::0;;-1:-1:-1;;;33560:40:0;;::::1;;::::0;::::1;::::0;::::1;::::0;;;;-1:-1:-1;;;;;;;;;;;33560:40:0;;;;;;;;;;;;;::::1;33539:64;33620:71;33637:10;33649:9;33660:10;33672:7;33681:9;33620:16;:71::i;32548:172::-:0;30489:3;;-1:-1:-1;;;;;30489:3:0;30475:10;:17;30467:51;;;;;-1:-1:-1;;;30467:51:0;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;30467:51:0;;;;;;;;;;;;;;;32647:11:::1;:26:::0;;;;32684:12:::1;:28:::0;32548:172::o;30854:50::-;-1:-1:-1;;;30854:50:0;:::o;32309:231::-;30489:3;;-1:-1:-1;;;;;30489:3:0;30475:10;:17;30467:51;;;;;-1:-1:-1;;;30467:51:0;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;30467:51:0;;;;;;;;;;;;;;;31008:8:::1;32401:17;:42;;32393:92;;;;-1:-1:-1::0;;;32393:92:0::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;32496:16;:36:::0;32309:231::o;32180:121::-;30489:3;;-1:-1:-1;;;;;30489:3:0;30475:10;:17;30467:51;;;;;-1:-1:-1;;;30467:51:0;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;30467:51:0;;;;;;;;;;;;;;;-1:-1:-1;;;;;32262:19:0;;;::::1;;::::0;;;:9:::1;:19;::::0;;;;:31;;-1:-1:-1;;32262:31:0::1;::::0;::::1;;::::0;;;::::1;::::0;;32180:121::o;31231:27::-;;;;:::o;30546:76::-;30489:3;;-1:-1:-1;;;;;30489:3:0;30475:10;:17;30467:51;;;;;-1:-1:-1;;;30467:51:0;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;30467:51:0;;;;;;;;;;;;;;;30604:3:::1;:10:::0;;-1:-1:-1;;;;;;30604:10:0::1;-1:-1:-1::0;;;;;30604:10:0;;;::::1;::::0;;;::::1;::::0;;30546:76::o;34016:218::-;34112:16;;;34126:1;34112:16;;;34056;34112;;;;;34056;;;34112;34126:1;34112:16;;;;;;;;;;-1:-1:-1;34112:16:0;34085:43;;34152:12;34159:4;34152:6;:12::i;:::-;34139:7;34147:1;34139:10;;;;;;;;;;;;;:25;;;;;34188:13;34195:5;34188:6;:13::i;:::-;34175:7;34183:1;34175:10;;;;;;;;;;;;;;;;;:26;34219:7;-1:-1:-1;34016:218:0;:::o;31051:19::-;;;-1:-1:-1;;;;;31051:19:0;;:::o;31025:::-;;;-1:-1:-1;;;;;31025:19:0;;:::o;2369:471::-;2427:7;2672:6;2668:47;;-1:-1:-1;2702:1:0;2695:8;;2668:47;2739:5;;;2743:1;2739;:5;:1;2763:5;;;;;:10;2755:56;;;;-1:-1:-1;;;2755:56:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2831:1;-1:-1:-1;2369:471:0;;;;;:::o;3316:132::-;3374:7;3401:39;3405:1;3408;3401:39;;;;;;;;;;;;;-1:-1:-1;;;3401:39:0;;;:3;:39::i;1015:181::-;1073:7;1105:5;;;1129:6;;;;1121:46;;;;;-1:-1:-1;;;1121:46:0;;;;;;;;;;;;-1:-1:-1;;;1121:46:0;;;;;;;;;;;;;;1479:136;1537:7;1564:43;1568:1;1571;1564:43;;;;;;;;;;;;;;;;;:3;:43::i;38574:115::-;38644:10;38634:21;;;;:9;:21;;;;;;;;38626:55;;;;;-1:-1:-1;;;38626:55:0;;;;;;;;;;;;-1:-1:-1;;;38626:55:0;;;;;;;;;;;;;;;38574:115::o;36351:1037::-;36502:7;36540:1;36530:7;:11;36522:51;;;;;-1:-1:-1;;;36522:51:0;;;;;;;;;;;;-1:-1:-1;;;36522:51:0;;;;;;;;;;;;;;;36627:17;36647:18;36660:4;36647:12;:18::i;:::-;36627:38;;36676:17;36703:3;;;;;;;;;-1:-1:-1;;;;;36703:3:0;-1:-1:-1;;;;;36696:23:0;;:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;36696:25:0;36791:5;;36696:25;;-1:-1:-1;36734:73:0;;-1:-1:-1;;;;;36734:31:0;;;;36766:15;;36791:5;36799:7;36734:31;:73::i;:::-;36839:5;;:36;;;-1:-1:-1;;;36839:36:0;;-1:-1:-1;;;;;36839:36:0;;;;;;;36869:4;36839:36;;;;;;36818:18;;36839:5;;;;;:13;;:36;;;;;;;;;;;;;;;36818:18;36839:5;:36;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;36839:36:0;;-1:-1:-1;36894:22:0;;;;36886:71;;;;-1:-1:-1;;;36886:71:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;36970:18;36991:14;;:70;;37021:40;37051:9;37021:25;:10;37036:9;37021:14;:25::i;:40::-;36991:70;;;37008:10;36991:70;36970:91;;37094:7;37080:10;:21;;37072:69;;;;-1:-1:-1;;;37072:69:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;37164:3;;;37154:41;;;-1:-1:-1;;;37154:41:0;;-1:-1:-1;;;;;37154:41:0;;;;;;;;;;;;;;;;;;37164:3;;;;;37154:19;;:41;;;;;37164:3;;37154:41;;;;;;;;37164:3;;37154:41;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;;;37208:21:0;;;;;;;:11;:21;;;;;;;;;37232:15;37208:39;;37265:85;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;37265:85:0;;;;;;;;37370:10;36351:1037;-1:-1:-1;;;;;;;;;;36351:1037:0:o;37396:1170::-;37532:7;37573:1;37560:10;:14;37552:57;;;;;-1:-1:-1;;;37552:57:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;37654:16;;-1:-1:-1;;;;;37628:21:0;;;;;;:11;:21;;;;;;37675:15;;37628:43;;:21;:25;:43::i;:::-;:62;;37620:119;;;;-1:-1:-1;;;37620:119:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;37794:17;37814:19;37827:5;37814:12;:19::i;:::-;37794:39;;37844:17;37871:3;;;;;;;;;-1:-1:-1;;;;;37871:3:0;-1:-1:-1;;;;;37864:23:0;;:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;37864:25:0;;-1:-1:-1;37902:18:0;37923:40;37864:25;37923;:10;37938:9;37923:14;:25::i;:40::-;38003:4;;37996:37;;;-1:-1:-1;;;37996:37:0;;38027:4;37996:37;;;;;;37902:61;;-1:-1:-1;37974:19:0;;-1:-1:-1;;;;;38003:4:0;;;;37996:22;;:37;;;;;;;;;;;;;;;38003:4;37996:37;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;37996:37:0;;-1:-1:-1;38048:24:0;;;38044:117;;;38095:4;;-1:-1:-1;;;;;38095:4:0;38089:16;38114:4;38121:27;:10;38136:11;38121:14;:27::i;:::-;38089:60;;;;;;;;;;;;;-1:-1:-1;;;;;38089:60:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;38044:117;38183:3;;;38173:41;;;-1:-1:-1;;;38173:41:0;;-1:-1:-1;;;;;38173:41:0;;;;;;;;;;;;;;;;;;38183:3;;;;;38173:19;;:41;;;;;38183:3;;38173:41;;;;;;;;38183:3;;38173:41;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;38234:4:0;;38257:5;;38227:49;;;-1:-1:-1;;;38227:49:0;;-1:-1:-1;;;;;38257:5:0;;;38227:49;;;;;;;;;;;;38234:4;;;;;-1:-1:-1;38227:21:0;;-1:-1:-1;38227:49:0;;;;;;;;;;;;;;38234:4;;38227:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;38307:5:0;;:36;;;-1:-1:-1;;;38307:36:0;;-1:-1:-1;;;;;38307:36:0;;;;;;;;;;;;;;;;38287:17;;38307:5;;;;;:14;;:36;;;;;38227:49;;38307:36;;;;;;;;38287:17;38307:5;:36;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;38307:36:0;;-1:-1:-1;38362:20:0;;;;38354:64;;;;;-1:-1:-1;;;38354:64:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;38436:93;;;-1:-1:-1;;;;;38436:93:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;38549:9;37396:1170;-1:-1:-1;;;;;;;;;;37396:1170:0:o;3944:278::-;4030:7;4065:12;4058:5;4050:28;;;;-1:-1:-1;;;4050:28:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4089:9;4105:1;4101;:5;;;;;;;3944:278;-1:-1:-1;;;;;3944:278:0:o;1918:192::-;2004:7;2040:12;2032:6;;;;2024:29;;;;-1:-1:-1;;;2024:29:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;2076:5:0;;;1918:192::o;17117:205::-;17245:68;;;-1:-1:-1;;;;;17245:68:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;17245:68:0;-1:-1:-1;;;17245:68:0;;;17218:96;;17238:5;;17218:19;:96::i;:::-;17117:205;;;;:::o;19237:761::-;19661:23;19687:69;19715:4;19687:69;;;;;;;;;;;;;;;;;19695:5;-1:-1:-1;;;;;19687:27:0;;;:69;;;;;:::i;:::-;19771:17;;19661:95;;-1:-1:-1;19771:21:0;19767:224;;19913:10;19902:30;;;;;;;;;;;;;;;-1:-1:-1;19902:30:0;19894:85;;;;-1:-1:-1;;;19894:85:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;19237:761;;;:::o;11946:195::-;12049:12;12081:52;12103:6;12111:4;12117:1;12120:12;12081:21;:52::i;:::-;12074:59;11946:195;-1:-1:-1;;;;11946:195:0:o;12998:530::-;13125:12;13183:5;13158:21;:30;;13150:81;;;;-1:-1:-1;;;13150:81:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13250:18;13261:6;13250:10;:18::i;:::-;13242:60;;;;;-1:-1:-1;;;13242:60:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;13376:12;13390:23;13417:6;-1:-1:-1;;;;;13417:11:0;13437:5;13445:4;13417:33;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;13417:33:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13375:75;;;;13468:52;13486:7;13495:10;13507:12;13468:17;:52::i;:::-;13461:59;12998:530;-1:-1:-1;;;;;;;12998:530:0:o;9028:422::-;9395:20;9434:8;;;9028:422::o;15538:742::-;15653:12;15682:7;15678:595;;;-1:-1:-1;15713:10:0;15706:17;;15678:595;15827:17;;:21;15823:439;;16090:10;16084:17;16151:15;16138:10;16134:2;16130:19;16123:44;16038:148;16226:20;;-1:-1:-1;;;16226:20:0;;;;;;;;;;;;;;;;;16233:12;;16226:20;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

Metadata Hash

c95e4ff2832feb7b25d2dc7e7dc18d46d4b152da9ba0434600660091a9a552da
Block Transaction Gas Used Reward
Age Block Fee Address BC Fee Address Voting Power Jailed Incoming
Block Uncle Number Difficulty Gas Used Reward
Loading
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.