Contract 0x489ee077994b6658eafa855c308275ead8097c4a

 
Txn Hash
Block
From
To
Value [Txn Fee]
0x4efd59d6df9576508509777e11a4f258bd9475c4d4566485add00a96e398602c25961062021-10-27 4:24:101 hr 31 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000902694104 ETH
0xda2f8dec42325519ee09a9440007855b96924002d001bf397af06b30b049e90625961022021-10-27 4:24:101 hr 31 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.00090567403 ETH
0x8cb4a7e521a2efa1b6f85f5b183da808343de4be381395e31cc202d24788600625961012021-10-27 4:24:101 hr 31 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.001185423227 ETH
0xa0cf3e6587649dca64378bf7e0890f637a3994ada82d28732f8c12943aa8112425864542021-10-26 22:55:157 hrs ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000900903598 ETH
0x51440e18b762ccc8a6e4515211c79dea5d209a5f055d880edb79e343c8ac2c8b25864492021-10-26 22:55:157 hrs ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.001185355535 ETH
0x9e9ac275e596a7d5b1e61610804131f15a4b0b1d543079a28a9317fd34bc9c2625864482021-10-26 22:55:157 hrs ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000903867334 ETH
0xff9bef321e8fa94adc33d9771e13dd8e6b4588da751fd40be17fd42b4b473ca625864452021-10-26 22:55:157 hrs ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000902382777 ETH
0x8eea99b83f97b5eca6aeb36ba20fb420e0c2e313cd5a6eebcc5cc2bac4ca633c25864422021-10-26 22:55:157 hrs ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000903867334 ETH
0x985ec389f7018fea32ccb4614fb6d0360d05ef99283ff678bd7d51bd6705f16125864402021-10-26 22:55:157 hrs ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000973021886 ETH
0x82a58d27d479f125f43a36548f9d647930a1a46e2fc4d093bef11e1ba3245e4525858652021-10-26 22:37:507 hrs 17 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000903869486 ETH
0x8c05bb92061b0863384368c6b3f607f33b340e22142aa679bd073e41e5f8fd7d25858632021-10-26 22:37:507 hrs 17 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000903869486 ETH
0xe3597deff883c5244158229c2f92e08b8034a72f60aa454146796d8bb572520b25858612021-10-26 22:37:507 hrs 17 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000973885726 ETH
0x5a758d759870c6381e5b170acb9beb4d5732380f6f84f04bcc1b943e963ff25f25858602021-10-26 22:37:507 hrs 17 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000903867334 ETH
0xf4640aadfb98e29f430162b1056f7e0c06ad559d9896694fa363a1eb5be3d97525858582021-10-26 22:37:507 hrs 17 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.001186812122 ETH
0xa8d300938365235110e67b6724183184e1aa6ed349b1408ef2e86f4b14d94af425858392021-10-26 22:37:507 hrs 17 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000902388156 ETH
0x48985b1040f88ad0f688a5aaed754dcc160e500fed19b4b7a4ee9379a35dba3125858352021-10-26 22:37:507 hrs 17 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.001188181573 ETH
0xfa832404df6c3b19c8b839e127fe27bf86d5d1add6e7705188960703c7e1ae1d25858332021-10-26 22:37:507 hrs 17 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000903878092 ETH
0xcc20addb16b7619b1b00b4cde81bf3eb805712b3ce91dc786d28aa792655c7e025858302021-10-26 22:37:507 hrs 17 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000902393534 ETH
0x7f17f8c7c6d683394140b39c98e0c37673d5fac66cc35aa4bedd51e7a1040f5e25858282021-10-26 22:37:507 hrs 17 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.001186343088 ETH
0x68a39919f06ac77e07681e01d1b44c77e64ade087800b092ff8b6541819fb36d25858112021-10-26 22:37:507 hrs 17 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000902386004 ETH
0xc5508087568fc99a92a674b06f7af42f02ecf0949c0e3995a7a00c789816eb0825858092021-10-26 22:37:507 hrs 17 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000903870561 ETH
0x39833f20168b32904096c8ae30971cd63fc00a3cc03b1b680d92b135e1907fc625858052021-10-26 22:37:507 hrs 17 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.001186178496 ETH
0x00362336c0e3ea0235ac1d5af5315501e966b64e73bd5f160a468aab5ddc084225858032021-10-26 22:37:507 hrs 17 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000914826164 ETH
0x7db68b792bc29d92bba5ecc0311c82f38edb42a00a3225381be09a4191bd55e625857982021-10-26 22:37:507 hrs 17 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000900898219 ETH
0x3007e785ca9702cd283806a05ac95aed79d24de6cc7ae0ddee57dc6e8474657425857952021-10-26 22:37:507 hrs 17 mins ago0x44311c91008dde73de521cd25136fd37d616802c IN  0x489ee077994b6658eafa855c308275ead8097c4a0 ETH0.000903867334 ETH
[ Download CSV Export 
Parent Txn Hash Block From To Value
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
Vault

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.io 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/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/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/IVaultPriceFeed.sol


pragma solidity 0.6.12;

interface IVaultPriceFeed {
    function adjustmentBasisPoints(address _token) external view returns (uint256);
    function isAdjustmentAdditive(address _token) external view returns (bool);
    function setAdjustment(address _token, bool _isAdditive, uint256 _adjustmentBps) external;
    function setUseV2Pricing(bool _useV2Pricing) external;
    function setIsAmmEnabled(bool _isEnabled) external;
    function setIsSecondaryPriceEnabled(bool _isEnabled) external;
    function setSpreadBasisPoints(address _token, uint256 _spreadBasisPoints) external;
    function setSpreadThresholdBasisPoints(uint256 _spreadThresholdBasisPoints) external;
    function setFavorPrimaryPrice(bool _favorPrimaryPrice) external;
    function setPriceSampleSpace(uint256 _priceSampleSpace) external;
    function setMaxStrictPriceDeviation(uint256 _maxStrictPriceDeviation) external;
    function getPrice(address _token, bool _maximise, bool _includeAmmPrice, bool _useSwapPricing) external view returns (uint256);
    function getAmmPrice(address _token) external view returns (uint256);
}


// File contracts/core/Vault.sol


pragma solidity 0.6.12;






contract Vault is ReentrancyGuard, IVault {
    using SafeMath for uint256;
    using SafeERC20 for IERC20;

    struct Position {
        uint256 size;
        uint256 collateral;
        uint256 averagePrice;
        uint256 entryFundingRate;
        uint256 reserveAmount;
        int256 realisedPnl;
        uint256 lastIncreasedTime;
    }

    uint256 public constant BASIS_POINTS_DIVISOR = 10000;
    uint256 public constant FUNDING_RATE_PRECISION = 1000000;
    uint256 public constant PRICE_PRECISION = 10 ** 30;
    uint256 public constant MIN_LEVERAGE = 10000; // 1x
    uint256 public constant USDG_DECIMALS = 18;
    uint256 public constant MAX_FEE_BASIS_POINTS = 500; // 5%
    uint256 public constant MAX_LIQUIDATION_FEE_USD = 100 * PRICE_PRECISION; // 100 USD
    uint256 public constant MIN_FUNDING_RATE_INTERVAL = 1 hours;
    uint256 public constant MAX_FUNDING_RATE_FACTOR = 10000; // 1%

    bool public override isInitialized;
    bool public override isSwapEnabled = true;
    bool public override isLeverageEnabled = true;

    address public errorController;

    address public override router;
    address public override priceFeed;

    address public override usdg;
    address public override gov;

    uint256 public override whitelistedTokenCount;

    uint256 public override maxLeverage = 50 * 10000; // 50x

    uint256 public override liquidationFeeUsd;
    uint256 public override taxBasisPoints = 50; // 0.5%
    uint256 public override stableTaxBasisPoints = 20; // 0.2%
    uint256 public override mintBurnFeeBasisPoints = 30; // 0.3%
    uint256 public override swapFeeBasisPoints = 30; // 0.3%
    uint256 public override stableSwapFeeBasisPoints = 4; // 0.04%
    uint256 public override marginFeeBasisPoints = 10; // 0.1%

    uint256 public override minProfitTime;
    bool public override hasDynamicFees = false;

    uint256 public override fundingInterval = 8 hours;
    uint256 public override fundingRateFactor;
    uint256 public override stableFundingRateFactor;
    uint256 public override totalTokenWeights;

    bool public includeAmmPrice = true;
    bool public useSwapPricing = false;

    bool public override inManagerMode = false;
    bool public override inPrivateLiquidationMode = false;

    uint256 public override maxGasPrice;

    mapping (address => mapping (address => bool)) public override approvedRouters;
    mapping (address => bool) public override isLiquidator;
    mapping (address => bool) public override isManager;

    address[] public override allWhitelistedTokens;

    mapping (address => bool) public override whitelistedTokens;
    mapping (address => uint256) public override tokenDecimals;
    mapping (address => uint256) public override minProfitBasisPoints;
    mapping (address => bool) public override stableTokens;
    mapping (address => bool) public override shortableTokens;

    // tokenBalances is used only to determine _transferIn values
    mapping (address => uint256) public override tokenBalances;

    // tokenWeights allows customisation of index composition
    mapping (address => uint256) public override tokenWeights;

    // usdgAmounts tracks the amount of USDG debt for each whitelisted token
    mapping (address => uint256) public override usdgAmounts;

    // maxUsdgAmounts allows setting a max amount of USDG debt for a token
    mapping (address => uint256) public override maxUsdgAmounts;

    // poolAmounts tracks the number of received tokens that can be used for leverage
    // this is tracked separately from tokenBalances to exclude funds that are deposited as margin collateral
    mapping (address => uint256) public override poolAmounts;

    // reservedAmounts tracks the number of tokens reserved for open leverage positions
    mapping (address => uint256) public override reservedAmounts;

    // bufferAmounts allows specification of an amount to exclude from swaps
    // this can be used to ensure a certain amount of liquidity is available for leverage positions
    mapping (address => uint256) public override bufferAmounts;

    // guaranteedUsd tracks the amount of USD that is "guaranteed" by opened leverage positions
    // this value is used to calculate the redemption values for selling of USDG
    // this is an estimated amount, it is possible for the actual guaranteed value to be lower
    // in the case of sudden price decreases, the guaranteed value should be corrected
    // after liquidations are carried out
    mapping (address => uint256) public override guaranteedUsd;

    // cumulativeFundingRates tracks the funding rates based on utilization
    mapping (address => uint256) public override cumulativeFundingRates;
    // lastFundingTimes tracks the last time funding was updated for a token
    mapping (address => uint256) public override lastFundingTimes;

    // positions tracks all open positions
    mapping (bytes32 => Position) public positions;

    // feeReserves tracks the amount of fees per token
    mapping (address => uint256) public override feeReserves;

    mapping (address => uint256) public override globalShortSizes;
    mapping (address => uint256) public override globalShortAveragePrices;

    mapping (uint256 => string) public errors;

    event BuyUSDG(address account, address token, uint256 tokenAmount, uint256 usdgAmount, uint256 feeBasisPoints);
    event SellUSDG(address account, address token, uint256 usdgAmount, uint256 tokenAmount, uint256 feeBasisPoints);
    event Swap(address account, address tokenIn, address tokenOut, uint256 amountIn, uint256 amountOut, uint256 amountOutAfterFees, uint256 feeBasisPoints);

    event IncreasePosition(
        bytes32 key,
        address account,
        address collateralToken,
        address indexToken,
        uint256 collateralDelta,
        uint256 sizeDelta,
        bool isLong,
        uint256 price,
        uint256 fee
    );
    event DecreasePosition(
        bytes32 key,
        address account,
        address collateralToken,
        address indexToken,
        uint256 collateralDelta,
        uint256 sizeDelta,
        bool isLong,
        uint256 price,
        uint256 fee
    );
    event LiquidatePosition(
        bytes32 key,
        address account,
        address collateralToken,
        address indexToken,
        bool isLong,
        uint256 size,
        uint256 collateral,
        uint256 reserveAmount,
        int256 realisedPnl,
        uint256 markPrice
    );
    event UpdatePosition(
        bytes32 key,
        uint256 size,
        uint256 collateral,
        uint256 averagePrice,
        uint256 entryFundingRate,
        uint256 reserveAmount,
        int256 realisedPnl
    );
    event ClosePosition(
        bytes32 key,
        uint256 size,
        uint256 collateral,
        uint256 averagePrice,
        uint256 entryFundingRate,
        uint256 reserveAmount,
        int256 realisedPnl
    );

    event UpdateFundingRate(address token, uint256 fundingRate);
    event UpdatePnl(bytes32 key, bool hasProfit, uint256 delta);

    event CollectSwapFees(address token, uint256 feeUsd, uint256 feeTokens);
    event CollectMarginFees(address token, uint256 feeUsd, uint256 feeTokens);

    event DirectPoolDeposit(address token, uint256 amount);
    event IncreasePoolAmount(address token, uint256 amount);
    event DecreasePoolAmount(address token, uint256 amount);
    event IncreaseUsdgAmount(address token, uint256 amount);
    event DecreaseUsdgAmount(address token, uint256 amount);
    event IncreaseReservedAmount(address token, uint256 amount);
    event DecreaseReservedAmount(address token, uint256 amount);
    event IncreaseGuaranteedUsd(address token, uint256 amount);
    event DecreaseGuaranteedUsd(address token, uint256 amount);

    // once the parameters are verified to be working correctly,
    // gov should be set to a timelock contract or a governance contract
    constructor() public {
        gov = msg.sender;
    }

    function initialize(
        address _router,
        address _usdg,
        address _priceFeed,
        uint256 _liquidationFeeUsd,
        uint256 _fundingRateFactor,
        uint256 _stableFundingRateFactor
    ) external {
        _onlyGov();
        _validate(!isInitialized, 1);
        isInitialized = true;

        router = _router;
        usdg = _usdg;
        priceFeed = _priceFeed;
        liquidationFeeUsd = _liquidationFeeUsd;
        fundingRateFactor = _fundingRateFactor;
        stableFundingRateFactor = _stableFundingRateFactor;
    }

    function setErrorController(address _errorController) external {
        _onlyGov();
        errorController = _errorController;
    }

    function setError(uint256 _errorCode, string calldata _error) external override {
        require(msg.sender == errorController, "Vault: invalid errorController");
        errors[_errorCode] = _error;
    }

    function allWhitelistedTokensLength() external override view returns (uint256) {
        return allWhitelistedTokens.length;
    }

    function setInManagerMode(bool _inManagerMode) external override {
        _onlyGov();
        inManagerMode = _inManagerMode;
    }

    function setManager(address _manager, bool _isManager) external override {
        _onlyGov();
        isManager[_manager] = _isManager;
    }

    function setInPrivateLiquidationMode(bool _inPrivateLiquidationMode) external {
        _onlyGov();
        inPrivateLiquidationMode = _inPrivateLiquidationMode;
    }

    function setLiquidator(address _liquidator, bool _isActive) external {
        _onlyGov();
        isLiquidator[_liquidator] = _isActive;
    }

    function setIsSwapEnabled(bool _isSwapEnabled) external override {
        _onlyGov();
        isSwapEnabled = _isSwapEnabled;
    }

    function setIsLeverageEnabled(bool _isLeverageEnabled) external override {
        _onlyGov();
        isLeverageEnabled = _isLeverageEnabled;
    }

    function setMaxGasPrice(uint256 _maxGasPrice) external override {
        _onlyGov();
        maxGasPrice = _maxGasPrice;
    }

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

    function setPriceFeed(address _priceFeed) external override {
        _onlyGov();
        priceFeed = _priceFeed;
    }

    function setMaxLeverage(uint256 _maxLeverage) external {
        _onlyGov();
        _validate(_maxLeverage > MIN_LEVERAGE, 2);
        maxLeverage = _maxLeverage;
    }

    function setBufferAmount(address _token, uint256 _amount) external {
        _onlyGov();
        bufferAmounts[_token] = _amount;
    }

    function setFees(
        uint256 _taxBasisPoints,
        uint256 _stableTaxBasisPoints,
        uint256 _mintBurnFeeBasisPoints,
        uint256 _swapFeeBasisPoints,
        uint256 _stableSwapFeeBasisPoints,
        uint256 _marginFeeBasisPoints,
        uint256 _liquidationFeeUsd,
        uint256 _minProfitTime,
        bool _hasDynamicFees
    ) external override {
        _onlyGov();
        _validate(_taxBasisPoints <= MAX_FEE_BASIS_POINTS, 3);
        _validate(_stableTaxBasisPoints <= MAX_FEE_BASIS_POINTS, 4);
        _validate(_mintBurnFeeBasisPoints <= MAX_FEE_BASIS_POINTS, 5);
        _validate(_swapFeeBasisPoints <= MAX_FEE_BASIS_POINTS, 6);
        _validate(_stableSwapFeeBasisPoints <= MAX_FEE_BASIS_POINTS, 7);
        _validate(_marginFeeBasisPoints <= MAX_FEE_BASIS_POINTS, 8);
        _validate(_liquidationFeeUsd <= MAX_LIQUIDATION_FEE_USD, 9);
        taxBasisPoints = _taxBasisPoints;
        stableTaxBasisPoints = _stableTaxBasisPoints;
        mintBurnFeeBasisPoints = _mintBurnFeeBasisPoints;
        swapFeeBasisPoints = _swapFeeBasisPoints;
        stableSwapFeeBasisPoints = _stableSwapFeeBasisPoints;
        marginFeeBasisPoints = _marginFeeBasisPoints;
        liquidationFeeUsd = _liquidationFeeUsd;
        minProfitTime = _minProfitTime;
        hasDynamicFees = _hasDynamicFees;
    }

    function setFundingRate(uint256 _fundingInterval, uint256 _fundingRateFactor, uint256 _stableFundingRateFactor) external {
        _onlyGov();
        _validate(_fundingInterval >= MIN_FUNDING_RATE_INTERVAL, 10);
        _validate(_fundingRateFactor <= MAX_FUNDING_RATE_FACTOR, 11);
        _validate(_stableFundingRateFactor <= MAX_FUNDING_RATE_FACTOR, 12);
        fundingInterval = _fundingInterval;
        fundingRateFactor = _fundingRateFactor;
        stableFundingRateFactor = _stableFundingRateFactor;
    }

    function setTokenConfig(
        address _token,
        uint256 _tokenDecimals,
        uint256 _tokenWeight,
        uint256 _minProfitBps,
        uint256 _maxUsdgAmount,
        bool _isStable,
        bool _isShortable
    ) external override {
        _onlyGov();
        // increment token count for the first time
        if (!whitelistedTokens[_token]) {
            whitelistedTokenCount = whitelistedTokenCount.add(1);
            allWhitelistedTokens.push(_token);
        }

        uint256 _totalTokenWeights = totalTokenWeights;
        _totalTokenWeights = _totalTokenWeights.sub(tokenWeights[_token]);

        whitelistedTokens[_token] = true;
        tokenDecimals[_token] = _tokenDecimals;
        tokenWeights[_token] = _tokenWeight;
        minProfitBasisPoints[_token] = _minProfitBps;
        maxUsdgAmounts[_token] = _maxUsdgAmount;
        stableTokens[_token] = _isStable;
        shortableTokens[_token] = _isShortable;

        totalTokenWeights = _totalTokenWeights.add(_tokenWeight);

        // validate price feed
        getMaxPrice(_token);
    }

    function clearTokenConfig(address _token) external {
        _onlyGov();
        _validate(whitelistedTokens[_token], 13);
        totalTokenWeights = totalTokenWeights.sub(tokenWeights[_token]);
        delete whitelistedTokens[_token];
        delete tokenDecimals[_token];
        delete tokenWeights[_token];
        delete minProfitBasisPoints[_token];
        delete maxUsdgAmounts[_token];
        delete stableTokens[_token];
        delete shortableTokens[_token];
        whitelistedTokenCount = whitelistedTokenCount.sub(1);
    }

    function withdrawFees(address _token, address _receiver) external override returns (uint256) {
        _onlyGov();
        uint256 amount = feeReserves[_token];
        if(amount == 0) { return 0; }
        feeReserves[_token] = 0;
        _transferOut(_token, amount, _receiver);
        return amount;
    }

    function addRouter(address _router) external {
        approvedRouters[msg.sender][_router] = true;
    }

    function removeRouter(address _router) external {
        approvedRouters[msg.sender][_router] = false;
    }

    function setUsdgAmount(address _token, uint256 _amount) external {
        _onlyGov();

        uint256 usdgAmount = usdgAmounts[_token];
        if (_amount > usdgAmount) {
            _increaseUsdgAmount(_token, _amount.sub(usdgAmount));
            return;
        }

        _decreaseUsdgAmount(_token, usdgAmount.sub(_amount));
    }

    // the governance controlling this function should have a timelock
    function upgradeVault(address _newVault, address _token, uint256 _amount) external {
        _onlyGov();
        IERC20(_token).safeTransfer(_newVault, _amount);
    }

    // deposit into the pool without minting USDG tokens
    // useful in allowing the pool to become over-collaterised
    function directPoolDeposit(address _token) external override nonReentrant {
        _validate(whitelistedTokens[_token], 14);
        uint256 tokenAmount = _transferIn(_token);
        _validate(tokenAmount > 0, 15);
        _increasePoolAmount(_token, tokenAmount);
        emit DirectPoolDeposit(_token, tokenAmount);
    }

    function buyUSDG(address _token, address _receiver) external override nonReentrant returns (uint256) {
        _validateManager();
        _validate(whitelistedTokens[_token], 16);

        uint256 tokenAmount = _transferIn(_token);
        _validate(tokenAmount > 0, 17);

        updateCumulativeFundingRate(_token);

        uint256 price = getMinPrice(_token);

        uint256 usdgAmount = tokenAmount.mul(price).div(PRICE_PRECISION);
        usdgAmount = adjustForDecimals(usdgAmount, _token, usdg);
        _validate(usdgAmount > 0, 18);

        uint256 feeBasisPoints = getFeeBasisPoints(_token, usdgAmount, mintBurnFeeBasisPoints, taxBasisPoints, true);
        uint256 amountAfterFees = _collectSwapFees(_token, tokenAmount, feeBasisPoints);
        uint256 mintAmount = amountAfterFees.mul(price).div(PRICE_PRECISION);
        mintAmount = adjustForDecimals(mintAmount, _token, usdg);

        _increaseUsdgAmount(_token, mintAmount);
        _increasePoolAmount(_token, amountAfterFees);

        IUSDG(usdg).mint(_receiver, mintAmount);

        emit BuyUSDG(_receiver, _token, tokenAmount, mintAmount, feeBasisPoints);

        useSwapPricing = false;
        return mintAmount;
    }

    function sellUSDG(address _token, address _receiver) external override nonReentrant returns (uint256) {
        _validateManager();
        _validate(whitelistedTokens[_token], 19);
        useSwapPricing = true;

        uint256 usdgAmount = _transferIn(usdg);
        _validate(usdgAmount > 0, 20);

        updateCumulativeFundingRate(_token);

        uint256 redemptionAmount = getRedemptionAmount(_token, usdgAmount);
        _validate(redemptionAmount > 0, 21);

        _decreaseUsdgAmount(_token, usdgAmount);
        _decreasePoolAmount(_token, redemptionAmount);

        IUSDG(usdg).burn(address(this), usdgAmount);

        // the _transferIn call increased the value of tokenBalances[usdg]
        // usually decreases in token balances are synced by calling _transferOut
        // however, for usdg, the tokens are burnt, so _updateTokenBalance should
        // be manually called to record the decrease in tokens
        _updateTokenBalance(usdg);

        uint256 feeBasisPoints = getFeeBasisPoints(_token, usdgAmount, mintBurnFeeBasisPoints, taxBasisPoints, false);
        uint256 amountOut = _collectSwapFees(_token, redemptionAmount, feeBasisPoints);
        _validate(amountOut > 0, 22);

        _transferOut(_token, amountOut, _receiver);

        emit SellUSDG(_receiver, _token, usdgAmount, amountOut, feeBasisPoints);

        useSwapPricing = false;
        return amountOut;
    }

    function swap(address _tokenIn, address _tokenOut, address _receiver) external override nonReentrant returns (uint256) {
        _validate(isSwapEnabled, 23);
        _validate(whitelistedTokens[_tokenIn], 24);
        _validate(whitelistedTokens[_tokenOut], 25);
        _validate(_tokenIn != _tokenOut, 26);

        useSwapPricing = true;

        updateCumulativeFundingRate(_tokenIn);
        updateCumulativeFundingRate(_tokenOut);

        uint256 amountIn = _transferIn(_tokenIn);
        _validate(amountIn > 0, 27);

        uint256 priceIn = getMinPrice(_tokenIn);
        uint256 priceOut = getMaxPrice(_tokenOut);

        uint256 amountOut = amountIn.mul(priceIn).div(priceOut);
        amountOut = adjustForDecimals(amountOut, _tokenIn, _tokenOut);

        // adjust usdgAmounts by the same usdgAmount as debt is shifted between the assets
        uint256 usdgAmount = amountIn.mul(priceIn).div(PRICE_PRECISION);
        usdgAmount = adjustForDecimals(usdgAmount, _tokenIn, usdg);

        bool isStableSwap = stableTokens[_tokenIn] && stableTokens[_tokenOut];
        uint256 feeBasisPoints;
        {
            uint256 baseBps = isStableSwap ? stableSwapFeeBasisPoints : swapFeeBasisPoints;
            uint256 taxBps = isStableSwap ? stableTaxBasisPoints : taxBasisPoints;
            uint256 feesBasisPoints0 = getFeeBasisPoints(_tokenIn, usdgAmount, baseBps, taxBps, true);
            uint256 feesBasisPoints1 = getFeeBasisPoints(_tokenOut, usdgAmount, baseBps, taxBps, false);
            // use the higher of the two fee basis points
            feeBasisPoints = feesBasisPoints0 > feesBasisPoints1 ? feesBasisPoints0 : feesBasisPoints1;
        }
        uint256 amountOutAfterFees = _collectSwapFees(_tokenOut, amountOut, feeBasisPoints);

        _increaseUsdgAmount(_tokenIn, usdgAmount);
        _decreaseUsdgAmount(_tokenOut, usdgAmount);

        _increasePoolAmount(_tokenIn, amountIn);
        _decreasePoolAmount(_tokenOut, amountOut);

        _validateBufferAmount(_tokenOut);

        _transferOut(_tokenOut, amountOutAfterFees, _receiver);

        emit Swap(_receiver, _tokenIn, _tokenOut, amountIn, amountOut, amountOutAfterFees, feeBasisPoints);

        useSwapPricing = false;
        return amountOutAfterFees;
    }

    function increasePosition(address _account, address _collateralToken, address _indexToken, uint256 _sizeDelta, bool _isLong) external override nonReentrant {
        _validate(isLeverageEnabled, 28);
        _validateGasPrice();
        _validateRouter(_account);
        _validateTokens(_collateralToken, _indexToken, _isLong);
        updateCumulativeFundingRate(_collateralToken);

        bytes32 key = getPositionKey(_account, _collateralToken, _indexToken, _isLong);
        Position storage position = positions[key];

        uint256 price = _isLong ? getMaxPrice(_indexToken) : getMinPrice(_indexToken);

        if (position.size == 0) {
            position.averagePrice = price;
        }

        if (position.size > 0 && _sizeDelta > 0) {
            position.averagePrice = getNextAveragePrice(_indexToken, position.size, position.averagePrice, _isLong, price, _sizeDelta, position.lastIncreasedTime);
        }

        uint256 fee = _collectMarginFees(_collateralToken, _sizeDelta, position.size, position.entryFundingRate);
        uint256 collateralDelta = _transferIn(_collateralToken);
        uint256 collateralDeltaUsd = tokenToUsdMin(_collateralToken, collateralDelta);

        position.collateral = position.collateral.add(collateralDeltaUsd);
        _validate(position.collateral >= fee, 29);

        position.collateral = position.collateral.sub(fee);
        position.entryFundingRate = cumulativeFundingRates[_collateralToken];
        position.size = position.size.add(_sizeDelta);
        position.lastIncreasedTime = block.timestamp;

        _validate(position.size > 0, 30);
        _validatePosition(position.size, position.collateral);
        validateLiquidation(_account, _collateralToken, _indexToken, _isLong, true);

        // reserve tokens to pay profits on the position
        uint256 reserveDelta = usdToTokenMax(_collateralToken, _sizeDelta);
        position.reserveAmount = position.reserveAmount.add(reserveDelta);
        _increaseReservedAmount(_collateralToken, reserveDelta);

        if (_isLong) {
            // guaranteedUsd stores the sum of (position.size - position.collateral) for all positions
            // if a fee is charged on the collateral then guaranteedUsd should be increased by that fee amount
            // since (position.size - position.collateral) would have increased by `fee`
            _increaseGuaranteedUsd(_collateralToken, _sizeDelta.add(fee));
            _decreaseGuaranteedUsd(_collateralToken, collateralDeltaUsd);
            // treat the deposited collateral as part of the pool
            _increasePoolAmount(_collateralToken, collateralDelta);
            // fees need to be deducted from the pool since fees are deducted from position.collateral
            // and collateral is treated as part of the pool
            _decreasePoolAmount(_collateralToken, usdToTokenMin(_collateralToken, fee));
        } else {
            if (globalShortSizes[_indexToken] == 0) {
                globalShortAveragePrices[_indexToken] = price;
            } else {
                globalShortAveragePrices[_indexToken] = getNextGlobalShortAveragePrice(_indexToken, price, _sizeDelta);
            }
            globalShortSizes[_indexToken] = globalShortSizes[_indexToken].add(_sizeDelta);
        }

        emit IncreasePosition(key, _account, _collateralToken, _indexToken, collateralDeltaUsd, _sizeDelta, _isLong, price, fee);
        emit UpdatePosition(key, position.size, position.collateral, position.averagePrice, position.entryFundingRate, position.reserveAmount, position.realisedPnl);
    }

    function decreasePosition(address _account, address _collateralToken, address _indexToken, uint256 _collateralDelta, uint256 _sizeDelta, bool _isLong, address _receiver) external override nonReentrant returns (uint256) {
        _validateGasPrice();
        _validateRouter(_account);
        return _decreasePosition(_account, _collateralToken, _indexToken, _collateralDelta, _sizeDelta, _isLong, _receiver);
    }

    function _decreasePosition(address _account, address _collateralToken, address _indexToken, uint256 _collateralDelta, uint256 _sizeDelta, bool _isLong, address _receiver) private returns (uint256) {
        updateCumulativeFundingRate(_collateralToken);

        bytes32 key = getPositionKey(_account, _collateralToken, _indexToken, _isLong);
        Position storage position = positions[key];
        _validate(position.size > 0, 31);
        _validate(position.size >= _sizeDelta, 32);
        _validate(position.collateral >= _collateralDelta, 33);

        uint256 collateral = position.collateral;
        // scrop variables to avoid stack too deep errors
        {
        uint256 reserveDelta = position.reserveAmount.mul(_sizeDelta).div(position.size);
        position.reserveAmount = position.reserveAmount.sub(reserveDelta);
        _decreaseReservedAmount(_collateralToken, reserveDelta);
        }

        (uint256 usdOut, uint256 usdOutAfterFee) = _reduceCollateral(_account, _collateralToken, _indexToken, _collateralDelta, _sizeDelta, _isLong);

        if (position.size != _sizeDelta) {
            position.entryFundingRate = cumulativeFundingRates[_collateralToken];
            position.size = position.size.sub(_sizeDelta);

            _validatePosition(position.size, position.collateral);
            validateLiquidation(_account, _collateralToken, _indexToken, _isLong, true);

            if (_isLong) {
                _increaseGuaranteedUsd(_collateralToken, collateral.sub(position.collateral));
                _decreaseGuaranteedUsd(_collateralToken, _sizeDelta);
            }

            uint256 price = _isLong ? getMinPrice(_indexToken) : getMaxPrice(_indexToken);
            emit DecreasePosition(key, _account, _collateralToken, _indexToken, _collateralDelta, _sizeDelta, _isLong, price, usdOut.sub(usdOutAfterFee));
            emit UpdatePosition(key, position.size, position.collateral, position.averagePrice, position.entryFundingRate, position.reserveAmount, position.realisedPnl);
        } else {
            if (_isLong) {
                _increaseGuaranteedUsd(_collateralToken, collateral);
                _decreaseGuaranteedUsd(_collateralToken, _sizeDelta);
            }

            uint256 price = _isLong ? getMinPrice(_indexToken) : getMaxPrice(_indexToken);
            emit DecreasePosition(key, _account, _collateralToken, _indexToken, _collateralDelta, _sizeDelta, _isLong, price, usdOut.sub(usdOutAfterFee));
            emit ClosePosition(key, position.size, position.collateral, position.averagePrice, position.entryFundingRate, position.reserveAmount, position.realisedPnl);

            delete positions[key];
        }

        if (!_isLong) {
            _decreaseGlobalShortSize(_indexToken, _sizeDelta);
        }

        if (usdOut > 0) {
            if (_isLong) {
                _decreasePoolAmount(_collateralToken, usdToTokenMin(_collateralToken, usdOut));
            }
            uint256 amountOutAfterFees = usdToTokenMin(_collateralToken, usdOutAfterFee);
            _transferOut(_collateralToken, amountOutAfterFees, _receiver);
            return amountOutAfterFees;
        }

        return 0;
    }

    function liquidatePosition(address _account, address _collateralToken, address _indexToken, bool _isLong, address _feeReceiver) external nonReentrant {
        if (inPrivateLiquidationMode) {
            _validate(isLiquidator[msg.sender], 34);
        }

        // set includeAmmPrice to false prevent manipulated liquidations
        includeAmmPrice = false;

        updateCumulativeFundingRate(_collateralToken);

        bytes32 key = getPositionKey(_account, _collateralToken, _indexToken, _isLong);
        Position memory position = positions[key];
        _validate(position.size > 0, 35);

        (uint256 liquidationState, uint256 marginFees) = validateLiquidation(_account, _collateralToken, _indexToken, _isLong, false);
        _validate(liquidationState != 0, 36);
        if (liquidationState == 2) {
            // max leverage exceeded but there is collateral remaining after deducting losses so decreasePosition instead
            _decreasePosition(_account, _collateralToken, _indexToken, 0, position.size, _isLong, _account);
            return;
        }

        uint256 feeTokens = usdToTokenMin(_collateralToken, marginFees);
        feeReserves[_collateralToken] = feeReserves[_collateralToken].add(feeTokens);
        emit CollectMarginFees(_collateralToken, marginFees, feeTokens);

        _decreaseReservedAmount(_collateralToken, position.reserveAmount);
        if (_isLong) {
            _decreaseGuaranteedUsd(_collateralToken, position.size.sub(position.collateral));
            _decreasePoolAmount(_collateralToken, usdToTokenMin(_collateralToken, marginFees));
        }

        uint256 markPrice = _isLong ? getMinPrice(_indexToken) : getMaxPrice(_indexToken);
        emit LiquidatePosition(key, _account, _collateralToken, _indexToken, _isLong, position.size, position.collateral, position.reserveAmount, position.realisedPnl, markPrice);

        if (!_isLong && marginFees < position.collateral) {
            uint256 remainingCollateral = position.collateral.sub(marginFees);
            _increasePoolAmount(_collateralToken, usdToTokenMin(_collateralToken, remainingCollateral));
        }

        if (!_isLong) {
            _decreaseGlobalShortSize(_indexToken, position.size);
        }

        delete positions[key];

        // pay the fee receiver using the pool, we assume that in general the liquidated amount should be sufficient to cover
        // the liquidation fees
        _decreasePoolAmount(_collateralToken, usdToTokenMin(_collateralToken, liquidationFeeUsd));
        _transferOut(_collateralToken, usdToTokenMin(_collateralToken, liquidationFeeUsd), _feeReceiver);

        includeAmmPrice = true;
    }

    // validateLiquidation returns (state, fees)
    function validateLiquidation(address _account, address _collateralToken, address _indexToken, bool _isLong, bool _raise) public view returns (uint256, uint256) {
        bytes32 key = getPositionKey(_account, _collateralToken, _indexToken, _isLong);
        Position memory position = positions[key];

        (bool hasProfit, uint256 delta) = getDelta(_indexToken, position.size, position.averagePrice, _isLong, position.lastIncreasedTime);
        uint256 marginFees = getFundingFee(_collateralToken, position.size, position.entryFundingRate);
        marginFees = marginFees.add(getPositionFee(position.size));

        if (!hasProfit && position.collateral < delta) {
            if (_raise) { revert("Vault: losses exceed collateral"); }
            return (1, marginFees);
        }

        uint256 remainingCollateral = position.collateral;
        if (!hasProfit) {
            remainingCollateral = position.collateral.sub(delta);
        }

        if (remainingCollateral < marginFees) {
            if (_raise) { revert("Vault: fees exceed collateral"); }
            // cap the fees to the remainingCollateral
            return (1, remainingCollateral);
        }

        if (remainingCollateral < marginFees.add(liquidationFeeUsd)) {
            if (_raise) { revert("Vault: liquidation fees exceed collateral"); }
            return (1, marginFees);
        }

        if (remainingCollateral.mul(maxLeverage) < position.size.mul(BASIS_POINTS_DIVISOR)) {
            if (_raise) { revert("Vault: maxLeverage exceeded"); }
            return (2, marginFees);
        }

        return (0, marginFees);
    }

    function getMaxPrice(address _token) public override view returns (uint256) {
        return IVaultPriceFeed(priceFeed).getPrice(_token, true, includeAmmPrice, useSwapPricing);
    }

    function getMinPrice(address _token) public override view returns (uint256) {
        return IVaultPriceFeed(priceFeed).getPrice(_token, false, includeAmmPrice, useSwapPricing);
    }

    function getRedemptionAmount(address _token, uint256 _usdgAmount) public override view returns (uint256) {
        uint256 price = getMaxPrice(_token);
        uint256 redemptionAmount = _usdgAmount.mul(PRICE_PRECISION).div(price);
        return adjustForDecimals(redemptionAmount, usdg, _token);
    }

    function getRedemptionCollateral(address _token) public view returns (uint256) {
        if (stableTokens[_token]) {
            return poolAmounts[_token];
        }
        uint256 collateral = usdToTokenMin(_token, guaranteedUsd[_token]);
        return collateral.add(poolAmounts[_token]).sub(reservedAmounts[_token]);
    }

    function getRedemptionCollateralUsd(address _token) public view returns (uint256) {
        return tokenToUsdMin(_token, getRedemptionCollateral(_token));
    }

    function adjustForDecimals(uint256 _amount, address _tokenDiv, address _tokenMul) public view returns (uint256) {
        uint256 decimalsDiv = _tokenDiv == usdg ? USDG_DECIMALS : tokenDecimals[_tokenDiv];
        uint256 decimalsMul = _tokenMul == usdg ? USDG_DECIMALS : tokenDecimals[_tokenMul];
        return _amount.mul(10 ** decimalsMul).div(10 ** decimalsDiv);
    }

    function tokenToUsdMin(address _token, uint256 _tokenAmount) public override view returns (uint256) {
        if (_tokenAmount == 0) { return 0; }
        uint256 price = getMinPrice(_token);
        uint256 decimals = tokenDecimals[_token];
        return _tokenAmount.mul(price).div(10 ** decimals);
    }

    function usdToTokenMax(address _token, uint256 _usdAmount) public view returns (uint256) {
        if (_usdAmount == 0) { return 0; }
        return usdToToken(_token, _usdAmount, getMinPrice(_token));
    }

    function usdToTokenMin(address _token, uint256 _usdAmount) public view returns (uint256) {
        if (_usdAmount == 0) { return 0; }
        return usdToToken(_token, _usdAmount, getMaxPrice(_token));
    }

    function usdToToken(address _token, uint256 _usdAmount, uint256 _price) public view returns (uint256) {
        if (_usdAmount == 0) { return 0; }
        uint256 decimals = tokenDecimals[_token];
        return _usdAmount.mul(10 ** decimals).div(_price);
    }

    function getPosition(address _account, address _collateralToken, address _indexToken, bool _isLong) public override view returns (uint256, uint256, uint256, uint256, uint256, uint256, bool, uint256) {
        bytes32 key = getPositionKey(_account, _collateralToken, _indexToken, _isLong);
        Position memory position = positions[key];
        uint256 realisedPnl = position.realisedPnl > 0 ? uint256(position.realisedPnl) : uint256(-position.realisedPnl);
        return (
            position.size, // 0
            position.collateral, // 1
            position.averagePrice, // 2
            position.entryFundingRate, // 3
            position.reserveAmount, // 4
            realisedPnl, // 5
            position.realisedPnl >= 0, // 6
            position.lastIncreasedTime // 7
        );
    }

    function getPositionKey(address _account, address _collateralToken, address _indexToken, bool _isLong) public pure returns (bytes32) {
        return keccak256(abi.encodePacked(
            _account,
            _collateralToken,
            _indexToken,
            _isLong
        ));
    }

    function updateCumulativeFundingRate(address _token) public {
        if (lastFundingTimes[_token] == 0) {
            lastFundingTimes[_token] = block.timestamp.div(fundingInterval).mul(fundingInterval);
            return;
        }

        if (lastFundingTimes[_token].add(fundingInterval) > block.timestamp) {
            return;
        }

        uint256 fundingRate = getNextFundingRate(_token);
        cumulativeFundingRates[_token] = cumulativeFundingRates[_token].add(fundingRate);
        lastFundingTimes[_token] = block.timestamp.div(fundingInterval).mul(fundingInterval);

        emit UpdateFundingRate(_token, cumulativeFundingRates[_token]);
    }

    function getNextFundingRate(address _token) public override view returns (uint256) {
        if (lastFundingTimes[_token].add(fundingInterval) > block.timestamp) { return 0; }

        uint256 intervals = block.timestamp.sub(lastFundingTimes[_token]).div(fundingInterval);
        uint256 poolAmount = poolAmounts[_token];
        if (poolAmount == 0) { return 0; }

        uint256 _fundingRateFactor = stableTokens[_token] ? stableFundingRateFactor : fundingRateFactor;
        return _fundingRateFactor.mul(reservedAmounts[_token]).mul(intervals).div(poolAmount);
    }

    function getUtilisation(address _token) public view returns (uint256) {
        uint256 poolAmount = poolAmounts[_token];
        if (poolAmount == 0) { return 0; }

        return reservedAmounts[_token].mul(FUNDING_RATE_PRECISION).div(poolAmount);
    }

    function getPositionLeverage(address _account, address _collateralToken, address _indexToken, bool _isLong) public view returns (uint256) {
        bytes32 key = getPositionKey(_account, _collateralToken, _indexToken, _isLong);
        Position memory position = positions[key];
        _validate(position.collateral > 0, 37);
        return position.size.mul(BASIS_POINTS_DIVISOR).div(position.collateral);
    }

    // for longs: nextAveragePrice = (nextPrice * nextSize)/ (nextSize + delta)
    // for shorts: nextAveragePrice = (nextPrice * nextSize) / (nextSize - delta)
    function getNextAveragePrice(address _indexToken, uint256 _size, uint256 _averagePrice, bool _isLong, uint256 _nextPrice, uint256 _sizeDelta, uint256 _lastIncreasedTime) public view returns (uint256) {
        (bool hasProfit, uint256 delta) = getDelta(_indexToken, _size, _averagePrice, _isLong, _lastIncreasedTime);
        uint256 nextSize = _size.add(_sizeDelta);
        uint256 divisor;
        if (_isLong) {
            divisor = hasProfit ? nextSize.add(delta) : nextSize.sub(delta);
        } else {
            divisor = hasProfit ? nextSize.sub(delta) : nextSize.add(delta);
        }
        return _nextPrice.mul(nextSize).div(divisor);
    }

    // for longs: nextAveragePrice = (nextPrice * nextSize)/ (nextSize + delta)
    // for shorts: nextAveragePrice = (nextPrice * nextSize) / (nextSize - delta)
    function getNextGlobalShortAveragePrice(address _indexToken, uint256 _nextPrice, uint256 _sizeDelta) public view returns (uint256) {
        uint256 size = globalShortSizes[_indexToken];
        uint256 averagePrice = globalShortAveragePrices[_indexToken];
        uint256 priceDelta = averagePrice > _nextPrice ? averagePrice.sub(_nextPrice) : _nextPrice.sub(averagePrice);
        uint256 delta = size.mul(priceDelta).div(averagePrice);
        bool hasProfit = averagePrice > _nextPrice;

        uint256 nextSize = size.add(_sizeDelta);
        uint256 divisor = hasProfit ? nextSize.sub(delta) : nextSize.add(delta);

        return _nextPrice.mul(nextSize).div(divisor);
    }

    function getGlobalShortDelta(address _token) public view returns (bool, uint256) {
        uint256 size = globalShortSizes[_token];
        if (size == 0) { return (false, 0); }

        uint256 nextPrice = getMaxPrice(_token);
        uint256 averagePrice = globalShortAveragePrices[_token];
        uint256 priceDelta = averagePrice > nextPrice ? averagePrice.sub(nextPrice) : nextPrice.sub(averagePrice);
        uint256 delta = size.mul(priceDelta).div(averagePrice);
        bool hasProfit = averagePrice > nextPrice;

        return (hasProfit, delta);
    }

    function getPositionDelta(address _account, address _collateralToken, address _indexToken, bool _isLong) public view returns (bool, uint256) {
        bytes32 key = getPositionKey(_account, _collateralToken, _indexToken, _isLong);
        Position memory position = positions[key];
        return getDelta(_indexToken, position.size, position.averagePrice, _isLong, position.lastIncreasedTime);
    }

    function getDelta(address _indexToken, uint256 _size, uint256 _averagePrice, bool _isLong, uint256 _lastIncreasedTime) public override view returns (bool, uint256) {
        _validate(_averagePrice > 0, 38);
        uint256 price = _isLong ? getMinPrice(_indexToken) : getMaxPrice(_indexToken);
        uint256 priceDelta = _averagePrice > price ? _averagePrice.sub(price) : price.sub(_averagePrice);
        uint256 delta = _size.mul(priceDelta).div(_averagePrice);

        bool hasProfit;

        if (_isLong) {
            hasProfit = price > _averagePrice;
        } else {
            hasProfit = _averagePrice > price;
        }

        // if the minProfitTime has passed then there will be no min profit threshold
        // the min profit threshold helps to prevent front-running issues
        uint256 minBps = block.timestamp > _lastIncreasedTime.add(minProfitTime) ? 0 : minProfitBasisPoints[_indexToken];
        if (hasProfit && delta.mul(BASIS_POINTS_DIVISOR) <= _size.mul(minBps)) {
            delta = 0;
        }

        return (hasProfit, delta);
    }

    function getFundingFee(address _token, uint256 _size, uint256 _entryFundingRate) public view returns (uint256) {
        if (_size == 0) { return 0; }

        uint256 fundingRate = cumulativeFundingRates[_token].sub(_entryFundingRate);
        if (fundingRate == 0) { return 0; }

        return _size.mul(fundingRate).div(FUNDING_RATE_PRECISION);
    }

    function getPositionFee(uint256 _sizeDelta) public view returns (uint256) {
        if (_sizeDelta == 0) { return 0; }
        uint256 afterFeeUsd = _sizeDelta.mul(BASIS_POINTS_DIVISOR.sub(marginFeeBasisPoints)).div(BASIS_POINTS_DIVISOR);
        return _sizeDelta.sub(afterFeeUsd);
    }

    // cases to consider
    // 1. initialAmount is far from targetAmount, action increases balance slightly => high rebate
    // 2. initialAmount is far from targetAmount, action increases balance largely => high rebate
    // 3. initialAmount is close to targetAmount, action increases balance slightly => low rebate
    // 4. initialAmount is far from targetAmount, action reduces balance slightly => high tax
    // 5. initialAmount is far from targetAmount, action reduces balance largely => high tax
    // 6. initialAmount is close to targetAmount, action reduces balance largely => low tax
    // 7. initialAmount is above targetAmount, nextAmount is below targetAmount and vice versa
    // 8. a large swap should have similar fees as the same trade split into multiple smaller swaps
    function getFeeBasisPoints(address _token, uint256 _usdgDelta, uint256 _feeBasisPoints, uint256 _taxBasisPoints, bool _increment) public override view returns (uint256) {
        if (!hasDynamicFees) { return _feeBasisPoints; }

        uint256 initialAmount = usdgAmounts[_token];
        uint256 nextAmount = initialAmount.add(_usdgDelta);
        if (!_increment) {
            nextAmount = _usdgDelta > initialAmount ? 0 : initialAmount.sub(_usdgDelta);
        }

        uint256 targetAmount = getTargetUsdgAmount(_token);
        if (targetAmount == 0) { return _feeBasisPoints; }

        uint256 initialDiff = initialAmount > targetAmount ? initialAmount.sub(targetAmount) : targetAmount.sub(initialAmount);
        uint256 nextDiff = nextAmount > targetAmount ? nextAmount.sub(targetAmount) : targetAmount.sub(nextAmount);

        // action improves relative asset balance
        if (nextDiff < initialDiff) {
            uint256 rebateBps = _taxBasisPoints.mul(initialDiff).div(targetAmount);
            return rebateBps > _feeBasisPoints ? 0 : _feeBasisPoints.sub(rebateBps);
        }

        uint256 averageDiff = initialDiff.add(nextDiff).div(2);
        if (averageDiff > targetAmount) {
            averageDiff = targetAmount;
        }
        uint256 taxBps = _taxBasisPoints.mul(averageDiff).div(targetAmount);
        return _feeBasisPoints.add(taxBps);
    }

    function getTargetUsdgAmount(address _token) public view returns (uint256) {
        uint256 supply = IERC20(usdg).totalSupply();
        if (supply == 0) { return 0; }
        uint256 weight = tokenWeights[_token];
        return weight.mul(supply).div(totalTokenWeights);
    }

    function _reduceCollateral(address _account, address _collateralToken, address _indexToken, uint256 _collateralDelta, uint256 _sizeDelta, bool _isLong) private returns (uint256, uint256) {
        bytes32 key = getPositionKey(_account, _collateralToken, _indexToken, _isLong);
        Position storage position = positions[key];

        uint256 fee = _collectMarginFees(_collateralToken, _sizeDelta, position.size, position.entryFundingRate);
        bool hasProfit;
        uint256 adjustedDelta;

        // scope variables to avoid stack too deep errors
        {
        (bool _hasProfit, uint256 delta) = getDelta(_indexToken, position.size, position.averagePrice, _isLong, position.lastIncreasedTime);
        hasProfit = _hasProfit;
        // get the proportional change in pnl
        adjustedDelta = _sizeDelta.mul(delta).div(position.size);
        }

        uint256 usdOut;
        // transfer profits out
        if (hasProfit && adjustedDelta > 0) {
            usdOut = adjustedDelta;
            position.realisedPnl = position.realisedPnl + int256(adjustedDelta);

            // pay out realised profits from the pool amount for short positions
            if (!_isLong) {
                uint256 tokenAmount = usdToTokenMin(_collateralToken, adjustedDelta);
                _decreasePoolAmount(_collateralToken, tokenAmount);
            }
        }

        if (!hasProfit && adjustedDelta > 0) {
            position.collateral = position.collateral.sub(adjustedDelta);

            // transfer realised losses to the pool for short positions
            // realised losses for long positions are not transferred here as
            // _increasePoolAmount was already called in increasePosition for longs
            if (!_isLong) {
                uint256 tokenAmount = usdToTokenMin(_collateralToken, adjustedDelta);
                _increasePoolAmount(_collateralToken, tokenAmount);
            }

            position.realisedPnl = position.realisedPnl - int256(adjustedDelta);
        }

        // reduce the position's collateral by _collateralDelta
        // transfer _collateralDelta out
        if (_collateralDelta > 0) {
            usdOut = usdOut.add(_collateralDelta);
            position.collateral = position.collateral.sub(_collateralDelta);
        }

        // if the position will be closed, then transfer the remaining collateral out
        if (position.size == _sizeDelta) {
            usdOut = usdOut.add(position.collateral);
            position.collateral = 0;
        }

        // if the usdOut is more than the fee then deduct the fee from the usdOut directly
        // else deduct the fee from the position's collateral
        uint256 usdOutAfterFee = usdOut;
        if (usdOut > fee) {
            usdOutAfterFee = usdOut.sub(fee);
        } else {
            position.collateral = position.collateral.sub(fee);
            if (_isLong) {
                uint256 feeTokens = usdToTokenMin(_collateralToken, fee);
                _decreasePoolAmount(_collateralToken, feeTokens);
            }
        }

        emit UpdatePnl(key, hasProfit, adjustedDelta);

        return (usdOut, usdOutAfterFee);
    }

    function _validatePosition(uint256 _size, uint256 _collateral) private view {
        if (_size == 0) {
            _validate(_collateral == 0, 39);
            return;
        }
        _validate(_size >= _collateral, 40);
    }

    function _validateRouter(address _account) private view {
        if (msg.sender == _account) { return; }
        if (msg.sender == router) { return; }
        _validate(approvedRouters[_account][msg.sender], 41);
    }

    function _validateTokens(address _collateralToken, address _indexToken, bool _isLong) private view {
        if (_isLong) {
            _validate(_collateralToken == _indexToken, 42);
            _validate(whitelistedTokens[_collateralToken], 43);
            _validate(!stableTokens[_collateralToken], 44);
            return;
        }

        _validate(whitelistedTokens[_collateralToken], 45);
        _validate(stableTokens[_collateralToken], 46);
        _validate(!stableTokens[_indexToken], 47);
        _validate(shortableTokens[_indexToken], 48);
    }

    function _collectSwapFees(address _token, uint256 _amount, uint256 _feeBasisPoints) private returns (uint256) {
        uint256 afterFeeAmount = _amount.mul(BASIS_POINTS_DIVISOR.sub(_feeBasisPoints)).div(BASIS_POINTS_DIVISOR);
        uint256 feeAmount = _amount.sub(afterFeeAmount);
        feeReserves[_token] = feeReserves[_token].add(feeAmount);
        emit CollectSwapFees(_token, feeAmount, tokenToUsdMin(_token, feeAmount));
        return afterFeeAmount;
    }

    function _collectMarginFees(address _token, uint256 _sizeDelta, uint256 _size, uint256 _entryFundingRate) private returns (uint256) {
        uint256 feeUsd = getPositionFee(_sizeDelta);

        uint256 fundingFee = getFundingFee(_token, _size, _entryFundingRate);
        feeUsd = feeUsd.add(fundingFee);

        uint256 feeTokens = usdToTokenMin(_token, feeUsd);
        feeReserves[_token] = feeReserves[_token].add(feeTokens);

        emit CollectMarginFees(_token, feeUsd, feeTokens);
        return feeUsd;
    }

    function _transferIn(address _token) private returns (uint256) {
        uint256 prevBalance = tokenBalances[_token];
        uint256 nextBalance = IERC20(_token).balanceOf(address(this));
        tokenBalances[_token] = nextBalance;

        return nextBalance.sub(prevBalance);
    }

    function _transferOut(address _token, uint256 _amount, address _receiver) private {
        IERC20(_token).safeTransfer(_receiver, _amount);
        tokenBalances[_token] = IERC20(_token).balanceOf(address(this));
    }

    function _updateTokenBalance(address _token) private {
        uint256 nextBalance = IERC20(_token).balanceOf(address(this));
        tokenBalances[_token] = nextBalance;
    }

    function _increasePoolAmount(address _token, uint256 _amount) private {
        poolAmounts[_token] = poolAmounts[_token].add(_amount);
        uint256 balance = IERC20(_token).balanceOf(address(this));
        _validate(poolAmounts[_token] <= balance, 49);
        emit IncreasePoolAmount(_token, _amount);
    }

    function _decreasePoolAmount(address _token, uint256 _amount) private {
        poolAmounts[_token] = poolAmounts[_token].sub(_amount, "Vault: poolAmount exceeded");
        _validate(reservedAmounts[_token] <= poolAmounts[_token], 50);
        emit DecreasePoolAmount(_token, _amount);
    }

    function _validateBufferAmount(address _token) private view {
        if (poolAmounts[_token] < bufferAmounts[_token]) {
            revert("Vault: poolAmount < buffer");
        }
    }

    function _increaseUsdgAmount(address _token, uint256 _amount) private {
        usdgAmounts[_token] = usdgAmounts[_token].add(_amount);
        uint256 maxUsdgAmount = maxUsdgAmounts[_token];
        if (maxUsdgAmount != 0) {
            _validate(usdgAmounts[_token] <= maxUsdgAmount, 51);
        }
        emit IncreaseUsdgAmount(_token, _amount);
    }

    function _decreaseUsdgAmount(address _token, uint256 _amount) private {
        uint256 value = usdgAmounts[_token];
        // since USDG can be minted using multiple assets
        // it is possible for the USDG debt for a single asset to be less than zero
        // the USDG debt is capped to zero for this case
        if (value <= _amount) {
            usdgAmounts[_token] = 0;
            emit DecreaseUsdgAmount(_token, value);
            return;
        }
        usdgAmounts[_token] = value.sub(_amount);
        emit DecreaseUsdgAmount(_token, _amount);
    }

    function _increaseReservedAmount(address _token, uint256 _amount) private {
        reservedAmounts[_token] = reservedAmounts[_token].add(_amount);
        _validate(reservedAmounts[_token] <= poolAmounts[_token], 52);
        emit IncreaseReservedAmount(_token, _amount);
    }

    function _decreaseReservedAmount(address _token, uint256 _amount) private {
        reservedAmounts[_token] = reservedAmounts[_token].sub(_amount, "Vault: insufficient reserve");
        emit DecreaseReservedAmount(_token, _amount);
    }

    function _increaseGuaranteedUsd(address _token, uint256 _usdAmount) private {
        guaranteedUsd[_token] = guaranteedUsd[_token].add(_usdAmount);
        emit IncreaseGuaranteedUsd(_token, _usdAmount);
    }

    function _decreaseGuaranteedUsd(address _token, uint256 _usdAmount) private {
        guaranteedUsd[_token] = guaranteedUsd[_token].sub(_usdAmount);
        emit DecreaseGuaranteedUsd(_token, _usdAmount);
    }

    function _decreaseGlobalShortSize(address _token, uint256 _amount) private {
        uint256 size = globalShortSizes[_token];
        if (_amount > size) {
          globalShortSizes[_token] = 0;
          return;
        }

        globalShortSizes[_token] = size.sub(_amount);
    }

    // we have this validation as a function instead of a modifier to reduce contract size
    function _onlyGov() private view {
        _validate(msg.sender == gov, 53);
    }

    // we have this validation as a function instead of a modifier to reduce contract size
    function _validateManager() private view {
        if (inManagerMode) {
            _validate(isManager[msg.sender], 54);
        }
    }

    // we have this validation as a function instead of a modifier to reduce contract size
    function _validateGasPrice() private view {
        if (maxGasPrice == 0) { return; }
        _validate(tx.gasprice <= maxGasPrice, 55);
    }

    function _validate(bool _condition, uint256 _errorCode) private view {
        require(_condition, errors[_errorCode]);
    }
}

Contract ABI

[{"inputs":[],"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":"tokenAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"usdgAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"feeBasisPoints","type":"uint256"}],"name":"BuyUSDG","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"key","type":"bytes32"},{"indexed":false,"internalType":"uint256","name":"size","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"collateral","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"averagePrice","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"entryFundingRate","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"reserveAmount","type":"uint256"},{"indexed":false,"internalType":"int256","name":"realisedPnl","type":"int256"}],"name":"ClosePosition","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"feeUsd","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"feeTokens","type":"uint256"}],"name":"CollectMarginFees","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"feeUsd","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"feeTokens","type":"uint256"}],"name":"CollectSwapFees","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"DecreaseGuaranteedUsd","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"DecreasePoolAmount","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"key","type":"bytes32"},{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"address","name":"collateralToken","type":"address"},{"indexed":false,"internalType":"address","name":"indexToken","type":"address"},{"indexed":false,"internalType":"uint256","name":"collateralDelta","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"sizeDelta","type":"uint256"},{"indexed":false,"internalType":"bool","name":"isLong","type":"bool"},{"indexed":false,"internalType":"uint256","name":"price","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"fee","type":"uint256"}],"name":"DecreasePosition","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"DecreaseReservedAmount","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"DecreaseUsdgAmount","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"DirectPoolDeposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"IncreaseGuaranteedUsd","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"IncreasePoolAmount","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"key","type":"bytes32"},{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"address","name":"collateralToken","type":"address"},{"indexed":false,"internalType":"address","name":"indexToken","type":"address"},{"indexed":false,"internalType":"uint256","name":"collateralDelta","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"sizeDelta","type":"uint256"},{"indexed":false,"internalType":"bool","name":"isLong","type":"bool"},{"indexed":false,"internalType":"uint256","name":"price","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"fee","type":"uint256"}],"name":"IncreasePosition","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"IncreaseReservedAmount","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"IncreaseUsdgAmount","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"key","type":"bytes32"},{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"address","name":"collateralToken","type":"address"},{"indexed":false,"internalType":"address","name":"indexToken","type":"address"},{"indexed":false,"internalType":"bool","name":"isLong","type":"bool"},{"indexed":false,"internalType":"uint256","name":"size","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"collateral","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"reserveAmount","type":"uint256"},{"indexed":false,"internalType":"int256","name":"realisedPnl","type":"int256"},{"indexed":false,"internalType":"uint256","name":"markPrice","type":"uint256"}],"name":"LiquidatePosition","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":"usdgAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"tokenAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"feeBasisPoints","type":"uint256"}],"name":"SellUSDG","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"address","name":"tokenIn","type":"address"},{"indexed":false,"internalType":"address","name":"tokenOut","type":"address"},{"indexed":false,"internalType":"uint256","name":"amountIn","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amountOut","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amountOutAfterFees","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"feeBasisPoints","type":"uint256"}],"name":"Swap","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"fundingRate","type":"uint256"}],"name":"UpdateFundingRate","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"key","type":"bytes32"},{"indexed":false,"internalType":"bool","name":"hasProfit","type":"bool"},{"indexed":false,"internalType":"uint256","name":"delta","type":"uint256"}],"name":"UpdatePnl","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"key","type":"bytes32"},{"indexed":false,"internalType":"uint256","name":"size","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"collateral","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"averagePrice","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"entryFundingRate","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"reserveAmount","type":"uint256"},{"indexed":false,"internalType":"int256","name":"realisedPnl","type":"int256"}],"name":"UpdatePosition","type":"event"},{"inputs":[],"name":"BASIS_POINTS_DIVISOR","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"FUNDING_RATE_PRECISION","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_FEE_BASIS_POINTS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_FUNDING_RATE_FACTOR","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_LIQUIDATION_FEE_USD","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MIN_FUNDING_RATE_INTERVAL","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MIN_LEVERAGE","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":"_router","type":"address"}],"name":"addRouter","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"address","name":"_tokenDiv","type":"address"},{"internalType":"address","name":"_tokenMul","type":"address"}],"name":"adjustForDecimals","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"allWhitelistedTokens","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"allWhitelistedTokensLength","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"}],"name":"approvedRouters","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"bufferAmounts","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"address","name":"_receiver","type":"address"}],"name":"buyUSDG","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"clearTokenConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"cumulativeFundingRates","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"address","name":"_collateralToken","type":"address"},{"internalType":"address","name":"_indexToken","type":"address"},{"internalType":"uint256","name":"_collateralDelta","type":"uint256"},{"internalType":"uint256","name":"_sizeDelta","type":"uint256"},{"internalType":"bool","name":"_isLong","type":"bool"},{"internalType":"address","name":"_receiver","type":"address"}],"name":"decreasePosition","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"directPoolDeposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"errorController","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"errors","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"feeReserves","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"fundingInterval","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"fundingRateFactor","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_indexToken","type":"address"},{"internalType":"uint256","name":"_size","type":"uint256"},{"internalType":"uint256","name":"_averagePrice","type":"uint256"},{"internalType":"bool","name":"_isLong","type":"bool"},{"internalType":"uint256","name":"_lastIncreasedTime","type":"uint256"}],"name":"getDelta","outputs":[{"internalType":"bool","name":"","type":"bool"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_usdgDelta","type":"uint256"},{"internalType":"uint256","name":"_feeBasisPoints","type":"uint256"},{"internalType":"uint256","name":"_taxBasisPoints","type":"uint256"},{"internalType":"bool","name":"_increment","type":"bool"}],"name":"getFeeBasisPoints","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_size","type":"uint256"},{"internalType":"uint256","name":"_entryFundingRate","type":"uint256"}],"name":"getFundingFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"getGlobalShortDelta","outputs":[{"internalType":"bool","name":"","type":"bool"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"getMaxPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"getMinPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_indexToken","type":"address"},{"internalType":"uint256","name":"_size","type":"uint256"},{"internalType":"uint256","name":"_averagePrice","type":"uint256"},{"internalType":"bool","name":"_isLong","type":"bool"},{"internalType":"uint256","name":"_nextPrice","type":"uint256"},{"internalType":"uint256","name":"_sizeDelta","type":"uint256"},{"internalType":"uint256","name":"_lastIncreasedTime","type":"uint256"}],"name":"getNextAveragePrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"getNextFundingRate","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_indexToken","type":"address"},{"internalType":"uint256","name":"_nextPrice","type":"uint256"},{"internalType":"uint256","name":"_sizeDelta","type":"uint256"}],"name":"getNextGlobalShortAveragePrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"address","name":"_collateralToken","type":"address"},{"internalType":"address","name":"_indexToken","type":"address"},{"internalType":"bool","name":"_isLong","type":"bool"}],"name":"getPosition","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bool","name":"","type":"bool"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"address","name":"_collateralToken","type":"address"},{"internalType":"address","name":"_indexToken","type":"address"},{"internalType":"bool","name":"_isLong","type":"bool"}],"name":"getPositionDelta","outputs":[{"internalType":"bool","name":"","type":"bool"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_sizeDelta","type":"uint256"}],"name":"getPositionFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"address","name":"_collateralToken","type":"address"},{"internalType":"address","name":"_indexToken","type":"address"},{"internalType":"bool","name":"_isLong","type":"bool"}],"name":"getPositionKey","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"address","name":"_collateralToken","type":"address"},{"internalType":"address","name":"_indexToken","type":"address"},{"internalType":"bool","name":"_isLong","type":"bool"}],"name":"getPositionLeverage","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_usdgAmount","type":"uint256"}],"name":"getRedemptionAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"getRedemptionCollateral","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"getRedemptionCollateralUsd","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"getTargetUsdgAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"getUtilisation","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"globalShortAveragePrices","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"globalShortSizes","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"gov","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"guaranteedUsd","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hasDynamicFees","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"inManagerMode","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"inPrivateLiquidationMode","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"includeAmmPrice","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"address","name":"_collateralToken","type":"address"},{"internalType":"address","name":"_indexToken","type":"address"},{"internalType":"uint256","name":"_sizeDelta","type":"uint256"},{"internalType":"bool","name":"_isLong","type":"bool"}],"name":"increasePosition","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_router","type":"address"},{"internalType":"address","name":"_usdg","type":"address"},{"internalType":"address","name":"_priceFeed","type":"address"},{"internalType":"uint256","name":"_liquidationFeeUsd","type":"uint256"},{"internalType":"uint256","name":"_fundingRateFactor","type":"uint256"},{"internalType":"uint256","name":"_stableFundingRateFactor","type":"uint256"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"isInitialized","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isLeverageEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"isLiquidator","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"isManager","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isSwapEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"lastFundingTimes","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"address","name":"_collateralToken","type":"address"},{"internalType":"address","name":"_indexToken","type":"address"},{"internalType":"bool","name":"_isLong","type":"bool"},{"internalType":"address","name":"_feeReceiver","type":"address"}],"name":"liquidatePosition","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"liquidationFeeUsd","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"marginFeeBasisPoints","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxGasPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxLeverage","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"maxUsdgAmounts","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"minProfitBasisPoints","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"minProfitTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"mintBurnFeeBasisPoints","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"poolAmounts","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"positions","outputs":[{"internalType":"uint256","name":"size","type":"uint256"},{"internalType":"uint256","name":"collateral","type":"uint256"},{"internalType":"uint256","name":"averagePrice","type":"uint256"},{"internalType":"uint256","name":"entryFundingRate","type":"uint256"},{"internalType":"uint256","name":"reserveAmount","type":"uint256"},{"internalType":"int256","name":"realisedPnl","type":"int256"},{"internalType":"uint256","name":"lastIncreasedTime","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"priceFeed","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_router","type":"address"}],"name":"removeRouter","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"reservedAmounts","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"router","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"address","name":"_receiver","type":"address"}],"name":"sellUSDG","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"setBufferAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_errorCode","type":"uint256"},{"internalType":"string","name":"_error","type":"string"}],"name":"setError","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_errorController","type":"address"}],"name":"setErrorController","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_taxBasisPoints","type":"uint256"},{"internalType":"uint256","name":"_stableTaxBasisPoints","type":"uint256"},{"internalType":"uint256","name":"_mintBurnFeeBasisPoints","type":"uint256"},{"internalType":"uint256","name":"_swapFeeBasisPoints","type":"uint256"},{"internalType":"uint256","name":"_stableSwapFeeBasisPoints","type":"uint256"},{"internalType":"uint256","name":"_marginFeeBasisPoints","type":"uint256"},{"internalType":"uint256","name":"_liquidationFeeUsd","type":"uint256"},{"internalType":"uint256","name":"_minProfitTime","type":"uint256"},{"internalType":"bool","name":"_hasDynamicFees","type":"bool"}],"name":"setFees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_fundingInterval","type":"uint256"},{"internalType":"uint256","name":"_fundingRateFactor","type":"uint256"},{"internalType":"uint256","name":"_stableFundingRateFactor","type":"uint256"}],"name":"setFundingRate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_gov","type":"address"}],"name":"setGov","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_inManagerMode","type":"bool"}],"name":"setInManagerMode","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_inPrivateLiquidationMode","type":"bool"}],"name":"setInPrivateLiquidationMode","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_isLeverageEnabled","type":"bool"}],"name":"setIsLeverageEnabled","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_isSwapEnabled","type":"bool"}],"name":"setIsSwapEnabled","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_liquidator","type":"address"},{"internalType":"bool","name":"_isActive","type":"bool"}],"name":"setLiquidator","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_manager","type":"address"},{"internalType":"bool","name":"_isManager","type":"bool"}],"name":"setManager","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_maxGasPrice","type":"uint256"}],"name":"setMaxGasPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_maxLeverage","type":"uint256"}],"name":"setMaxLeverage","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_priceFeed","type":"address"}],"name":"setPriceFeed","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_tokenDecimals","type":"uint256"},{"internalType":"uint256","name":"_tokenWeight","type":"uint256"},{"internalType":"uint256","name":"_minProfitBps","type":"uint256"},{"internalType":"uint256","name":"_maxUsdgAmount","type":"uint256"},{"internalType":"bool","name":"_isStable","type":"bool"},{"internalType":"bool","name":"_isShortable","type":"bool"}],"name":"setTokenConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"setUsdgAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"shortableTokens","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stableFundingRateFactor","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stableSwapFeeBasisPoints","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stableTaxBasisPoints","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"stableTokens","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_tokenIn","type":"address"},{"internalType":"address","name":"_tokenOut","type":"address"},{"internalType":"address","name":"_receiver","type":"address"}],"name":"swap","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"swapFeeBasisPoints","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"taxBasisPoints","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"tokenBalances","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"tokenDecimals","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_tokenAmount","type":"uint256"}],"name":"tokenToUsdMin","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"tokenWeights","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalTokenWeights","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"updateCumulativeFundingRate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_newVault","type":"address"},{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"upgradeVault","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_usdAmount","type":"uint256"},{"internalType":"uint256","name":"_price","type":"uint256"}],"name":"usdToToken","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_usdAmount","type":"uint256"}],"name":"usdToTokenMax","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_usdAmount","type":"uint256"}],"name":"usdToTokenMin","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"usdg","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"usdgAmounts","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"useSwapPricing","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"address","name":"_collateralToken","type":"address"},{"internalType":"address","name":"_indexToken","type":"address"},{"internalType":"bool","name":"_isLong","type":"bool"},{"internalType":"bool","name":"_raise","type":"bool"}],"name":"validateLiquidation","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"whitelistedTokenCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"whitelistedTokens","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"address","name":"_receiver","type":"address"}],"name":"withdrawFees","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"}]

60806040526001805462ff00001961ff00199091166101001716620100001781556207a12060075560326009556014600a908155601e600b819055600c556004600d55600e556010805460ff199081169091556170806011556015805463ffffff0019921690921716905534801561007657600080fd5b506001600055600580546001600160a01b03191633179055615b8e806200009e6000396000f3fe608060405234801561001057600080fd5b50600436106105325760003560e01c806304fef1db1461053757806307c587521461056f5780630842b076146105775780630a48d5a91461057f57806310eb56c2146105ab578063126082cf146105b357806312d43a51146105bb578063134ca63b146105df57806313f1e736146105e7578063174d26941461060f57806317bbf25c14610617578063181e210e146106345780631aa4ace5146106505780631ce9cb8f1461067657806324b0c04d1461069c57806324ca984e146106bb57806328e67be5146106e157806329ff9615146107565780632c668ec11461077c5780632d4b0576146107a857806330455ede146107e6578063318bc6891461080557806334c1557d146105b3578063351a964d1461080d578063392e53cd146108155780633a05dcc11461081d5780633c5a6e35146108435780633de39c11146108915780633e72a2621461089957806340eb3802146108a157806342152873146108f257806342b60b03146109265780634453a3741461094c57806345a6f3701461097a57806348d91abf146109d357806348f35cbb14610a175780634a3f088d14610a1f5780634a993ee914610aa05780634befe2ca14610ac65780634d47b30414610ace578063514ea4bf14610ad657806351723e8214610b2b578063523fba7f14610b69578063529a356f14610b8f57806352f55eed14610bb55780635c07eaab14610bdb5780635f7bc11914610c1b5780636092219914610c4157806362287a3214610c6f5780636274980314610c775780636ae0b15414610c9d5780636be6026b14610cc3578063711e619014610ccb578063724e78da14610cf9578063728cdbca14610d1f578063741bef1a14610d675780637a210a2b14610d6f5780637c2eb9f714610d77578063817bb85714610d9657806381a612d614610dc457806382a0849014610dea5780638585f4d214610e3e578063870d917c14610e6a57806388b1fbdf14610e725780638a27d46814610e985780638a39735a146105b35780638a78daa814610ec15780638ee573ac14610ee75780638f7b840414610f0d5780639060b1ca14610f335780639331621214610f3b57806395082d2514610f735780639849e41214610f7b5780639899cd0214610f835780639d7432ca14610faf5780639f392eb314610fe1578063a22f239214610fe9578063a42ab3d214610ff1578063a5e90eee1461101d578063a93acac21461104b578063ab08c1c614611071578063ab2f3ad414611079578063ad1e4f8d1461109f578063ae3302c2146110c5578063b06423f3146110cd578063b136ca49146110d5578063b364accb146110fb578063c3c7b9e914611121578063c4f718bf14611147578063c65bc7b11461114f578063c7e074c314611175578063cc5b8144146111b5578063cea0c328146111e7578063cfad57a21461121d578063d2fa635e14611243578063d3127e6314611260578063d54d5a9f1461127d578063d66b000d146112dc578063d8f897c314611308578063d9ac42251461132e578063daf9c21014611336578063db3555fb1461135c578063db97495f14611382578063dc8f5fac146113ce578063de2ea948146113d6578063df73a2671461141e578063e124e6d214611426578063e468baf01461144c578063e67f59a714611469578063f07456ce1461148f578063f07bbf77146114b5578063f2555278146114d4578063f3ae241514611502578063f5b91b7b14611528578063f887ea4014611530578063fa12dbc014611538578063fce28c101461156a578063fed1a60614611572575b600080fd5b61055d6004803603602081101561054d57600080fd5b50356001600160a01b0316611604565b60408051918252519081900360200190f35b61055d611667565b61055d611678565b61055d6004803603604081101561059557600080fd5b506001600160a01b03813516906020013561167e565b61055d6116d1565b61055d6116d7565b6105c36116dd565b604080516001600160a01b039092168252519081900360200190f35b61055d6116ec565b61060d600480360360208110156105fd57600080fd5b50356001600160a01b03166116f2565b005b61055d611835565b61055d6004803603602081101561062d57600080fd5b503561183b565b61063c61187f565b604080519115158252519081900360200190f35b61055d6004803603602081101561066657600080fd5b50356001600160a01b031661188f565b61055d6004803603602081101561068c57600080fd5b50356001600160a01b03166118a1565b61060d600480360360208110156106b257600080fd5b503515156118b3565b61060d600480360360208110156106d157600080fd5b50356001600160a01b03166118d7565b61060d600480360360408110156106f757600080fd5b81359190810190604081016020820135600160201b81111561071857600080fd5b82018360208201111561072a57600080fd5b803590602001918460018302840111600160201b8311171561074b57600080fd5b509092509050611908565b61055d6004803603602081101561076c57600080fd5b50356001600160a01b031661198d565b61055d6004803603604081101561079257600080fd5b506001600160a01b0381351690602001356119a1565b61055d600480360360808110156107be57600080fd5b506001600160a01b0381358116916020810135821691604082013516906060013515156119e6565b61060d600480360360208110156107fc57600080fd5b50351515611a3c565b61055d611a5e565b61063c611a64565b61063c611a72565b61055d6004803603602081101561083357600080fd5b50356001600160a01b0316611a7b565b61060d600480360360e081101561085957600080fd5b506001600160a01b038135169060208101359060408101359060608101359060808101359060a081013515159060c001351515611b2e565b61055d611c72565b61063c611c78565b61060d60048036036101208110156108b857600080fd5b5080359060208101359060408101359060608101359060808101359060a08101359060c08101359060e08101359061010001351515611c87565b61055d6004803603606081101561090857600080fd5b508035906001600160a01b0360208201358116916040013516611d41565b61063c6004803603602081101561093c57600080fd5b50356001600160a01b0316611de3565b61060d6004803603604081101561096257600080fd5b506001600160a01b0381351690602001351515611df8565b6109b86004803603608081101561099057600080fd5b506001600160a01b038135811691602081013582169160408201351690606001351515611e2b565b60408051921515835260208301919091528051918290030190f35b61060d600480360360a08110156109e957600080fd5b506001600160a01b038135811691602081013582169160408201351690606081013590608001351515611ec9565b6105c361229f565b610a5d60048036036080811015610a3557600080fd5b506001600160a01b0381358116916020810135821691604082013516906060013515156122b5565b604080519889526020890197909752878701959095526060870193909352608086019190915260a0850152151560c084015260e083015251908190036101000190f35b61055d60048036036020811015610ab657600080fd5b50356001600160a01b03166123ab565b61055d6123bd565b61055d6123c3565b610af360048036036020811015610aec57600080fd5b50356123c9565b604080519788526020880196909652868601949094526060860192909252608085015260a084015260c0830152519081900360e00190f35b61055d60048036036080811015610b4157600080fd5b506001600160a01b038135811691602081013582169160408201351690606001351515612406565b61055d60048036036020811015610b7f57600080fd5b50356001600160a01b03166124ac565b61063c60048036036020811015610ba557600080fd5b50356001600160a01b03166124bd565b61055d60048036036020811015610bcb57600080fd5b50356001600160a01b03166124d2565b6109b8600480360360a0811015610bf157600080fd5b506001600160a01b03813516906020810135906040810135906060810135151590608001356124e4565b61060d60048036036020811015610c3157600080fd5b50356001600160a01b03166125de565b61063c60048036036040811015610c5757600080fd5b506001600160a01b03813581169160200135166126c1565b61055d6126e1565b61055d60048036036020811015610c8d57600080fd5b50356001600160a01b03166126e7565b61060d60048036036020811015610cb357600080fd5b50356001600160a01b03166126f9565b61055d612727565b61055d60048036036040811015610ce157600080fd5b506001600160a01b038135811691602001351661272e565b61060d60048036036020811015610d0f57600080fd5b50356001600160a01b031661294c565b61060d600480360360c0811015610d3557600080fd5b506001600160a01b03813581169160208101358216916040820135169060608101359060808101359060a00135612976565b6105c36129ed565b61055d6129fc565b61060d60048036036020811015610d8d57600080fd5b50351515612a02565b61055d60048036036040811015610dac57600080fd5b506001600160a01b0381358116916020013516612a26565b61055d60048036036020811015610dda57600080fd5b50356001600160a01b0316612c74565b61055d600480360360e0811015610e0057600080fd5b506001600160a01b0381358116916020810135821691604082013581169160608101359160808201359160a081013515159160c09091013516612d1e565b61060d60048036036040811015610e5457600080fd5b506001600160a01b038135169060200135612d9c565b61055d612dc0565b61055d60048036036020811015610e8857600080fd5b50356001600160a01b0316612dc5565b61060d60048036036060811015610eae57600080fd5b5080359060208101359060400135612dd7565b61055d60048036036020811015610ed757600080fd5b50356001600160a01b0316612e1d565b61055d60048036036020811015610efd57600080fd5b50356001600160a01b0316612e2f565b61060d60048036036020811015610f2357600080fd5b50356001600160a01b0316612e41565b61063c612e75565b61055d60048036036060811015610f5157600080fd5b506001600160a01b038135811691602081013582169160409091013516612e84565b61055d61317d565b61055d61318d565b61055d60048036036040811015610f9957600080fd5b506001600160a01b038135169060200135613193565b61055d60048036036060811015610fc557600080fd5b506001600160a01b0381351690602081013590604001356131b5565b61063c61325e565b61055d613267565b61055d6004803603604081101561100757600080fd5b506001600160a01b03813516906020013561326d565b61060d6004803603604081101561103357600080fd5b506001600160a01b038135169060200135151561328a565b61055d6004803603602081101561106157600080fd5b50356001600160a01b03166132bd565b61063c6133b5565b61055d6004803603602081101561108f57600080fd5b50356001600160a01b03166133be565b61055d600480360360208110156110b557600080fd5b50356001600160a01b03166133d0565b61055d6133e2565b61063c6133e8565b61055d600480360360208110156110eb57600080fd5b50356001600160a01b03166133f6565b6109b86004803603602081101561111157600080fd5b50356001600160a01b0316613497565b61055d6004803603602081101561113757600080fd5b50356001600160a01b031661352f565b61055d613541565b61055d6004803603602081101561116557600080fd5b50356001600160a01b0316613547565b61055d600480360360a081101561118b57600080fd5b506001600160a01b0381351690602081013590604081013590606081013590608001351515613559565b61055d600480360360608110156111cb57600080fd5b506001600160a01b0381351690602081013590604001356136a4565b61060d600480360360608110156111fd57600080fd5b506001600160a01b038135811691602081013590911690604001356136f8565b61060d6004803603602081101561123357600080fd5b50356001600160a01b0316613719565b61060d6004803603602081101561125957600080fd5b5035613743565b61060d6004803603602081101561127657600080fd5b5035613750565b6112c3600480360360a081101561129357600080fd5b506001600160a01b038135811691602081013582169160408201351690606081013515159060800135151561376c565b6040805192835260208301919091528051918290030190f35b61060d600480360360408110156112f257600080fd5b506001600160a01b038135169060200135613a2c565b61055d6004803603602081101561131e57600080fd5b50356001600160a01b0316613a85565b61055d613a97565b61063c6004803603602081101561134c57600080fd5b50356001600160a01b0316613a9d565b61063c6004803603602081101561137257600080fd5b50356001600160a01b0316613ab2565b61055d600480360360e081101561139857600080fd5b506001600160a01b0381351690602081013590604081013590606081013515159060808101359060a08101359060c00135613ac7565b61055d613b58565b61060d600480360360a08110156113ec57600080fd5b506001600160a01b03813581169160208101358216916040820135811691606081013515159160809091013516613b5e565b61055d613f15565b61055d6004803603602081101561143c57600080fd5b50356001600160a01b0316613f1b565b6105c36004803603602081101561146257600080fd5b5035613f92565b61060d6004803603602081101561147f57600080fd5b50356001600160a01b0316613fb9565b61055d600480360360208110156114a557600080fd5b50356001600160a01b031661408e565b61060d600480360360208110156114cb57600080fd5b503515156140a0565b61055d600480360360408110156114ea57600080fd5b506001600160a01b03813581169160200135166140c6565b61063c6004803603602081101561151857600080fd5b50356001600160a01b031661411c565b6105c3614131565b6105c3614140565b61055d6004803603606081101561154e57600080fd5b506001600160a01b03813516906020810135906040013561414f565b61055d614189565b61158f6004803603602081101561158857600080fd5b503561418f565b6040805160208082528351818301528351919283929083019185019080838360005b838110156115c95781810151838201526020016115b1565b50505050905090810190601f1680156115f65780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6001600160a01b0381166000908152602460205260408120548061162c576000915050611662565b6001600160a01b03831660009081526025602052604090205461165e90829061165890620f424061422a565b90614283565b9150505b919050565b6904ee2d6d415b85acef8160201b81565b601a5490565b60008161168d575060006116cb565b600061169884612c74565b6001600160a01b0385166000908152601c60205260409020549091506116c6600a82900a611658868561422a565b925050505b92915050565b600a5481565b61271081565b6005546001600160a01b031681565b60135481565b6001600160a01b03811660009081526029602052604090205461174457601154611726906117204282614283565b9061422a565b6001600160a01b038216600090815260296020526040902055611832565b6011546001600160a01b038216600090815260296020526040902054429161176c91906142c2565b111561177757611832565b6000611782826132bd565b6001600160a01b0383166000908152602860205260409020549091506117a890826142c2565b6001600160a01b0383166000908152602860205260409020556011546117d2906117204282614283565b6001600160a01b03831660008181526029602090815260408083209490945560288152908390205483519283529082015281517fa146fc154e1913322e9817d49f0d5c37466c24326e15de10e739a948be815eab929181900390910190a1505b50565b60085481565b60008161184a57506000611662565b600061187361271061165861186c600e5461271061431a90919063ffffffff16565b869061422a565b905061165e838261431a565b6015546301000000900460ff1681565b60226020526000908152604090205481565b602b6020526000908152604090205481565b6118bb61435c565b60158054911515620100000262ff000019909216919091179055565b3360009081526017602090815260408083206001600160a01b0394909416835292905220805460ff19166001179055565b600154630100000090046001600160a01b0316331461196e576040805162461bcd60e51b815260206004820152601e60248201527f5661756c743a20696e76616c6964206572726f72436f6e74726f6c6c65720000604482015290519081900360640190fd5b6000838152602e60205260409020611987908383615974565b50505050565b60006116cb8261199c846133f6565b61167e565b6000806119ad84613f1b565b905060006119cb826116588668327cb2734119d3b7a9601e1b61422a565b6004549091506116c69082906001600160a01b031687611d41565b604080516001600160601b0319606096871b811660208084019190915295871b811660348301529390951b9092166048850152151560f81b605c8401528051603d818503018152605d9093019052815191012090565b611a4461435c565b600180549115156101000261ff0019909216919091179055565b600e5481565b600154610100900460ff1681565b60015460ff1681565b60048054604080516318160ddd60e01b8152905160009384936001600160a01b0316926318160ddd9281830192602092829003018186803b158015611abf57600080fd5b505afa158015611ad3573d6000803e3d6000fd5b505050506040513d6020811015611ae957600080fd5b5051905080611afc576000915050611662565b6001600160a01b038316600090815260216020526040902054601454611b2690611658838561422a565b949350505050565b611b3661435c565b6001600160a01b0387166000908152601b602052604090205460ff16611bb357600654611b649060016142c2565b600655601a80546001810182556000919091527f057c384a7d1c54f3a1b2e5e67b2617b8224fdfd1ea7234eea573a6ff665ff63e0180546001600160a01b0319166001600160a01b0389161790555b6014546001600160a01b038816600090815260216020526040902054611bda90829061431a565b6001600160a01b0389166000908152601b602090815260408083208054600160ff1991821617909155601c83528184208c9055602183528184208b9055601d83528184208a905560238352818420899055601e835281842080548216891515179055601f90925290912080549091168415151790559050611c5b81876142c2565b601455611c6788613f1b565b505050505050505050565b60165481565b60015462010000900460ff1681565b611c8f61435c565b611c9f6101f48a11156003614377565b611caf6101f48911156004614377565b611cbf6101f48811156005614377565b611ccf6101f48711156006614377565b611cdf6101f48611156007614377565b611cef6101f48511156008614377565b611d0a6904ee2d6d415b85acef8160201b8411156009614377565b600998909855600a96909655600b94909455600c92909255600d55600e55600855600f556010805460ff1916911515919091179055565b60045460009081906001600160a01b03858116911614611d79576001600160a01b0384166000908152601c6020526040902054611d7c565b60125b6004549091506000906001600160a01b03858116911614611db5576001600160a01b0384166000908152601c6020526040902054611db8565b60125b9050611dd782600a0a61165883600a0a8961422a90919063ffffffff16565b925050505b9392505050565b601e6020526000908152604090205460ff1681565b611e0061435c565b6001600160a01b03919091166000908152601860205260409020805460ff1916911515919091179055565b6000806000611e3c878787876119e6565b9050611e466159f2565b506000818152602a6020908152604091829020825160e081018452815480825260018301549382019390935260028201549381018490526003820154606082015260048201546080820152600582015460a082015260069091015460c082018190529092611eba92899290919089906124e4565b93509350505094509492505050565b60026000541415611f0f576040805162461bcd60e51b815260206004820152601f6024820152600080516020615a45833981519152604482015290519081900360640190fd5b6002600055600154611f2b9062010000900460ff16601c614377565b611f33614423565b611f3c8561443f565b611f4784848361449f565b611f50846116f2565b6000611f5e868686856119e6565b6000818152602a6020526040812091925083611f8257611f7d86612c74565b611f8b565b611f8b86613f1b565b8254909150611f9c57600282018190555b815415801590611fac5750600085115b15611fd257611fcc868360000154846002015487858a8860060154613ac7565b60028301555b6000611fe88887856000015486600301546145b5565b90506000611ff589614667565b905060006120038a8361167e565b600186015490915061201590826142c2565b6001860181905561202a90841115601d614377565b6001850154612039908461431a565b60018601556001600160a01b038a166000908152602860205260409020546003860155845461206890896142c2565b80865542600687015561207e901515601e614377565b61209085600001548660010154614711565b61209e8b8b8b8a600161376c565b505060006120ac8b8a61326d565b60048701549091506120be90826142c2565b60048701556120cd8b82614735565b8715612112576120e68b6120e18b876142c2565b6147d5565b6120f08b83614854565b6120fa8b846148d3565b61210d8b6121088d87613193565b6149ea565b6121b1565b6001600160a01b038a166000908152602c602052604090205461214f576001600160a01b038a166000908152602d60205260409020859055612174565b61215a8a868b6131b5565b6001600160a01b038b166000908152602d60205260409020555b6001600160a01b038a166000908152602c6020526040902054612197908a6142c2565b6001600160a01b038b166000908152602c60205260409020555b604080518881526001600160a01b03808f166020830152808e16828401528c1660608201526080810184905260a081018b905289151560c082015260e08101879052610100810186905290517f2fe68525253654c21998f35787a8d0f361905ef647c854092430ab65f2f15022918190036101200190a1855460018701546002880154600389015460048a015460058b0154604080518e81526020810197909752868101959095526060860193909352608085019190915260a084015260c083015251600080516020615a858339815191529181900360e00190a15050600160005550505050505050505050565b600154630100000090046001600160a01b031681565b60008060008060008060008060006122cf8d8d8d8d6119e6565b90506122d96159f2565b602a60008381526020019081526020016000206040518060e001604052908160008201548152602001600182015481526020016002820154815260200160038201548152602001600482015481526020016005820154815260200160068201548152505090506000808260a0015113612359578160a0015160000361235f565b8160a001515b9050816000015182602001518360400151846060015185608001518560008860a0015112158860c001519a509a509a509a509a509a509a509a5050505094995094995094999196509450565b60266020526000908152604090205481565b6101f481565b600b5481565b602a602052600090815260409020805460018201546002830154600384015460048501546005860154600690960154949593949293919290919087565b600080612415868686866119e6565b905061241f6159f2565b506000818152602a6020908152604091829020825160e0810184528154815260018201549281018390526002820154938101939093526003810154606084015260048101546080840152600581015460a08401526006015460c08301526124899015156025614377565b602081015181516124a191906116589061271061422a565b979650505050505050565b602080526000908152604090205481565b60186020526000908152604090205460ff1681565b60246020526000908152604090205481565b6000806124f5600086116026614377565b60008461250a5761250588613f1b565b612513565b61251388612c74565b9050600081871161252d57612528828861431a565b612537565b612537878361431a565b90506000612549886116588b8561422a565b90506000871561255c5750878311612561565b508288115b6000612578600f54896142c290919063ffffffff16565b421161259c576001600160a01b038c166000908152601d602052604090205461259f565b60005b90508180156125c257506125b38b8261422a565b6125bf8461271061422a565b11155b156125cc57600092505b509450925050505b9550959350505050565b60026000541415612624576040805162461bcd60e51b815260206004820152601f6024820152600080516020615a45833981519152604482015290519081900360640190fd5b600260009081556001600160a01b0382168152601b602052604090205461264f9060ff16600e614377565b600061265a82614667565b905061266a60008211600f614377565b61267482826148d3565b604080516001600160a01b03841681526020810183905281517fa5a389190ebf6170a133bda5c769b77f4d6715b8aa172ec0ddf8473d0b4944bd929181900390910190a150506001600055565b601760209081526000928352604080842090915290825290205460ff1681565b60065481565b602d6020526000908152604090205481565b3360009081526017602090815260408083206001600160a01b0394909416835292905220805460ff19169055565b620f424081565b600060026000541415612776576040805162461bcd60e51b815260206004820152601f6024820152600080516020615a45833981519152604482015290519081900360640190fd5b6002600055612783614abd565b6001600160a01b0383166000908152601b60205260409020546127aa9060ff166013614377565b6015805461ff0019166101001790556004546000906127d1906001600160a01b0316614667565b90506127e1600082116014614377565b6127ea846116f2565b60006127f685836119a1565b9050612806600082116015614377565b6128108583614aec565b61281a85826149ea565b6004805460408051632770a7eb60e21b8152309381019390935260248301859052516001600160a01b0390911691639dc29fac91604480830192600092919082900301818387803b15801561286e57600080fd5b505af1158015612882573d6000803e3d6000fd5b505060045461289c92506001600160a01b03169050614baa565b60006128b08684600b546009546000613559565b905060006128bf878484614c44565b90506128cf600082116016614377565b6128da878288614d0b565b604080516001600160a01b03808916825289166020820152808201869052606081018390526080810184905290517fd732b7828fa6cee72c285eac756fc66a7477e3dc22e22e7c432f1c265d40b4839181900360a00190a16015805461ff001916905560016000559695505050505050565b61295461435c565b600380546001600160a01b0319166001600160a01b0392909216919091179055565b61297e61435c565b600180546129929160ff9091161590614377565b6001805460ff191681179055600280546001600160a01b03199081166001600160a01b039889161790915560048054821696881696909617909555600380549095169390951692909217909255600891909155601255601355565b6003546001600160a01b031681565b60095481565b612a0a61435c565b60018054911515620100000262ff000019909216919091179055565b600060026000541415612a6e576040805162461bcd60e51b815260206004820152601f6024820152600080516020615a45833981519152604482015290519081900360640190fd5b6002600055612a7b614abd565b6001600160a01b0383166000908152601b6020526040902054612aa29060ff166010614377565b6000612aad84614667565b9050612abd600082116011614377565b612ac6846116f2565b6000612ad185612c74565b90506000612aef68327cb2734119d3b7a9601e1b611658858561422a565b600454909150612b0b90829088906001600160a01b0316611d41565b9050612b1b600082116012614377565b6000612b2f8783600b546009546001613559565b90506000612b3e888684614c44565b90506000612b5c68327cb2734119d3b7a9601e1b611658848861422a565b600454909150612b789082908b906001600160a01b0316611d41565b9050612b848982614db1565b612b8e89836148d3565b60048054604080516340c10f1960e01b81526001600160a01b038c81169482019490945260248101859052905192909116916340c10f199160448082019260009290919082900301818387803b158015612be757600080fd5b505af1158015612bfb573d6000803e3d6000fd5b5050604080516001600160a01b03808d1682528d1660208201528082018a9052606081018590526080810187905290517fab4c77c74cd32c85f35416cf03e7ce9e2d4387f7b7f2c1f4bf53daaecf8ea72d93509081900360a0019150a16015805461ff0019169055600160005598975050505050505050565b600354601554604080516317e1d38560e11b81526001600160a01b03858116600483015260006024830181905260ff8086161515604485015261010090950490941615156064830152915192939190911691632fc3a70a91608480820192602092909190829003018186803b158015612cec57600080fd5b505afa158015612d00573d6000803e3d6000fd5b505050506040513d6020811015612d1657600080fd5b505192915050565b600060026000541415612d66576040805162461bcd60e51b815260206004820152601f6024820152600080516020615a45833981519152604482015290519081900360640190fd5b6002600055612d73614423565b612d7c8861443f565b612d8b88888888888888614e6f565b600160005598975050505050505050565b612da461435c565b6001600160a01b03909116600090815260266020526040902055565b601281565b601d6020526000908152604090205481565b612ddf61435c565b612def610e10841015600a614377565b612dff612710831115600b614377565b612e0f612710821115600c614377565b601192909255601255601355565b602c6020526000908152604090205481565b601c6020526000908152604090205481565b612e4961435c565b600180546001600160a01b039092166301000000026301000000600160b81b0319909216919091179055565b60155462010000900460ff1681565b600060026000541415612ecc576040805162461bcd60e51b815260206004820152601f6024820152600080516020615a45833981519152604482015290519081900360640190fd5b6002600055600154612ee790610100900460ff166017614377565b6001600160a01b0384166000908152601b6020526040902054612f0e9060ff166018614377565b6001600160a01b0383166000908152601b6020526040902054612f359060ff166019614377565b612f55836001600160a01b0316856001600160a01b03161415601a614377565b6015805461ff001916610100179055612f6d846116f2565b612f76836116f2565b6000612f8185614667565b9050612f9160008211601b614377565b6000612f9c86612c74565b90506000612fa986613f1b565b90506000612fbb82611658868661422a565b9050612fc8818989611d41565b90506000612fe668327cb2734119d3b7a9601e1b611658878761422a565b6004549091506130029082908b906001600160a01b0316611d41565b6001600160a01b038a166000908152601e60205260408120549192509060ff16801561304657506001600160a01b0389166000908152601e602052604090205460ff165b90506000808261305857600c5461305c565b600d545b905060008361306d57600954613071565b600a545b905060006130838e8785856001613559565b905060006130958e8886866000613559565b90508082116130a457806130a6565b815b94505050505060006130b98b8684614c44565b90506130c58c85614db1565b6130cf8b85614aec565b6130d98c896148d3565b6130e38b866149ea565b6130ec8b615267565b6130f78b828c614d0b565b604080516001600160a01b03808d168252808f1660208301528d1681830152606081018a90526080810187905260a0810183905260c0810184905290517f0874b2d545cb271cdbda4e093020c452328b24af12382ed62c4d00f5c26709db9181900360e00190a16015805461ff001916905560016000559b9a5050505050505050505050565b68327cb2734119d3b7a9601e1b81565b60115481565b6000816131a2575060006116cb565b611ddc83836131b086613f1b565b61414f565b6001600160a01b0383166000908152602c6020908152604080832054602d909252822054828582116131f0576131eb868361431a565b6131fa565b6131fa828761431a565b9050600061320c83611658868561422a565b9050868311600061321d86896142c2565b90506000826132355761323082856142c2565b61323f565b61323f828561431a565b905061324f816116588c8561422a565b9b9a5050505050505050505050565b60105460ff1681565b600c5481565b60008161327c575060006116cb565b611ddc83836131b086612c74565b61329261435c565b6001600160a01b03919091166000908152601960205260409020805460ff1916911515919091179055565b6011546001600160a01b038216600090815260296020526040812054909142916132e6916142c2565b11156132f457506000611662565b6011546001600160a01b03831660009081526029602052604081205490916133219161165890429061431a565b6001600160a01b0384166000908152602460205260409020549091508061334d57600092505050611662565b6001600160a01b0384166000908152601e602052604081205460ff1661337557601254613379565b6013545b6001600160a01b0386166000908152602560205260409020549091506133ac90839061165890869061172090869061422a565b95945050505050565b60155460ff1681565b60216020526000908152604090205481565b60236020526000908152604090205481565b60075481565b601554610100900460ff1681565b6001600160a01b0381166000908152601e602052604081205460ff161561343657506001600160a01b038116600090815260246020526040902054611662565b6001600160a01b03821660009081526027602052604081205461345a908490613193565b6001600160a01b03841660009081526025602090815260408083205460249092529091205491925061165e916134919084906142c2565b9061431a565b6001600160a01b0381166000908152602c60205260408120548190806134c457600080925092505061352a565b60006134cf85613f1b565b6001600160a01b0386166000908152602d6020526040812054919250828211613501576134fc838361431a565b61350b565b61350b828461431a565b9050600061351d83611658878561422a565b9390921195509193505050505b915091565b60256020526000908152604090205481565b60125481565b60286020526000908152604090205481565b60105460009060ff1661356d5750826133ac565b6001600160a01b0386166000908152602260205260408120549061359182886142c2565b9050836135b4578187116135ae576135a9828861431a565b6135b1565b60005b90505b60006135bf89611a7b565b9050806135d1578693505050506133ac565b60008184116135e9576135e4828561431a565b6135f3565b6135f3848361431a565b9050600082841161360d57613608838561431a565b613617565b613617848461431a565b905081811015613659576000613631846116588b8661422a565b9050898111613649576136448a8261431a565b61364c565b60005b96505050505050506133ac565b600061366a600261165885856142c2565b9050838111156136775750825b6000613687856116588c8561422a565b90506136938b826142c2565b9d9c50505050505050505050505050565b6000826136b357506000611ddc565b6001600160a01b0384166000908152602860205260408120546136d6908461431a565b9050806136e7576000915050611ddc565b6133ac620f4240611658868461422a565b61370061435c565b6137146001600160a01b03831684836152dc565b505050565b61372161435c565b600580546001600160a01b0319166001600160a01b0392909216919091179055565b61374b61435c565b601655565b61375861435c565b61376761271082116002614377565b600755565b600080600061377d888888886119e6565b90506137876159f2565b506000818152602a60209081526040808320815160e081018352815480825260018301549482019490945260028201549281018390526003820154606082015260048201546080820152600582015460a082015260069091015460c0820181905290939283926137fc928c9291908c906124e4565b9150915060006138158b856000015186606001516136a4565b905061382e613827856000015161183b565b82906142c2565b9050821580156138415750818460200151105b156138a9578715613899576040805162461bcd60e51b815260206004820152601f60248201527f5661756c743a206c6f737365732065786365656420636f6c6c61746572616c00604482015290519081900360640190fd5b6001965094506125d49350505050565b6020840151836138c55760208501516138c2908461431a565b90505b81811015613931578815613920576040805162461bcd60e51b815260206004820152601d60248201527f5661756c743a20666565732065786365656420636f6c6c61746572616c000000604482015290519081900360640190fd5b6001975095506125d4945050505050565b60085461393f9083906142c2565b8110156139945788156139835760405162461bcd60e51b8152600401808060200182810382526029815260200180615aa56029913960400191505060405180910390fd5b506001965094506125d49350505050565b84516139a29061271061422a565b6007546139b090839061422a565b1015613a18578815613a07576040805162461bcd60e51b815260206004820152601b60248201527a15985d5b1d0e881b585e13195d995c9859d948195e18d959591959602a1b604482015290519081900360640190fd5b506002965094506125d49350505050565b5060009c909b509950505050505050505050565b613a3461435c565b6001600160a01b03821660009081526022602052604090205480821115613a6e57613a6883613a63848461431a565b614db1565b50613a81565b61371483613a7c838561431a565b614aec565b5050565b60296020526000908152604090205481565b600f5481565b601b6020526000908152604090205460ff1681565b601f6020526000908152604090205460ff1681565b6000806000613ad98a8a8a8a886124e4565b90925090506000613aea8a876142c2565b905060008815613b195783613b0857613b03828461431a565b613b12565b613b1282846142c2565b9050613b3a565b83613b2d57613b2882846142c2565b613b37565b613b37828461431a565b90505b613b48816116588a8561422a565b9c9b505050505050505050505050565b60145481565b60026000541415613ba4576040805162461bcd60e51b815260206004820152601f6024820152600080516020615a45833981519152604482015290519081900360640190fd5b60026000556015546301000000900460ff1615613bd95733600090815260186020526040902054613bd99060ff166022614377565b6015805460ff19169055613bec846116f2565b6000613bfa868686866119e6565b9050613c046159f2565b506000818152602a6020908152604091829020825160e08101845281548082526001830154938201939093526002820154938101939093526003810154606084015260048101546080840152600581015460a08401526006015460c0830152613c709015156023614377565b600080613c8189898989600061376c565b91509150613c9482600014156024614377565b8160021415613cbb57613cb1898989600087600001518b8f614e6f565b5050505050613f09565b6000613cc78983613193565b6001600160a01b038a166000908152602b6020526040902054909150613ced90826142c2565b6001600160a01b038a166000818152602b60209081526040918290209390935580519182529181018490528082018390529051600080516020615b398339815191529181900360600190a1613d4689856080015161532e565b8615613d755760208401518451613d67918b91613d629161431a565b614854565b613d75896121088b85613193565b600087613d8a57613d8589613f1b565b613d93565b613d9389612c74565b90507f2e1f85a64a2f22cf2f0c42584e7c919ed4abe8d53675cff0f62bf1e95a1c676f868c8c8c8c8a600001518b602001518c608001518d60a001518a604051808b81526020018a6001600160a01b03168152602001896001600160a01b03168152602001886001600160a01b0316815260200187151581526020018681526020018581526020018481526020018381526020018281526020019a505050505050505050505060405180910390a187158015613e525750846020015183105b15613e80576020850151600090613e69908561431a565b9050613e7e8b613e798d84613193565b6148d3565b505b87613e9357613e938986600001516153e3565b6000868152602a60205260408120818155600181018290556002810182905560038101829055600481018290556005810182905560060155600854613edf908b90612108908290613193565b613ef58a613eef8c600854613193565b89614d0b565b50506015805460ff19166001179055505050505b50506001600055505050565b600d5481565b600354601554604080516317e1d38560e11b81526001600160a01b0385811660048301526001602483015260ff808516151560448401526101009094049093161515606482015290516000939290921691632fc3a70a91608480820192602092909190829003018186803b158015612cec57600080fd5b601a8181548110613f9f57fe5b6000918252602090912001546001600160a01b0316905081565b613fc161435c565b6001600160a01b0381166000908152601b6020526040902054613fe89060ff16600d614377565b6001600160a01b03811660009081526021602052604090205460145461400d9161431a565b6014556001600160a01b0381166000908152601b60209081526040808320805460ff19908116909155601c835281842084905560218352818420849055601d835281842084905560238352818420849055601e8352818420805482169055601f9092529091208054909116905560065461408890600161431a565b60065550565b60276020526000908152604090205481565b6140a861435c565b6015805491151563010000000263ff00000019909216919091179055565b60006140d061435c565b6001600160a01b0383166000908152602b6020526040902054806140f85760009150506116cb565b6001600160a01b0384166000908152602b6020526040812055611ddc848285614d0b565b60196020526000908152604090205460ff1681565b6004546001600160a01b031681565b6002546001600160a01b031681565b60008261415e57506000611ddc565b6001600160a01b0384166000908152601c60205260409020546133ac8361165886600a85900a61422a565b610e1081565b602e6020908152600091825260409182902080548351601f6002600019610100600186161502019093169290920491820184900484028101840190945280845290918301828280156142225780601f106141f757610100808354040283529160200191614222565b820191906000526020600020905b81548152906001019060200180831161420557829003601f168201915b505050505081565b600082614239575060006116cb565b8282028284828161424657fe5b0414611ddc5760405162461bcd60e51b8152600401808060200182810382526021815260200180615ace6021913960400191505060405180910390fd5b6000611ddc83836040518060400160405280601a815260200179536166654d6174683a206469766973696f6e206279207a65726f60301b81525061544b565b600082820183811015611ddc576040805162461bcd60e51b815260206004820152601b60248201527a536166654d6174683a206164646974696f6e206f766572666c6f7760281b604482015290519081900360640190fd5b6000611ddc83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506154ed565b600554614375906001600160a01b031633146035614377565b565b6000818152602e60205260409020826137145760405162461bcd60e51b81526020600482019081528254600260001961010060018416150201909116046024830181905290918291604490910190849080156144145780601f106143e957610100808354040283529160200191614414565b820191906000526020600020905b8154815290600101906020018083116143f757829003601f168201915b50509250505060405180910390fd5b60165461442f57614375565b6143756016543a11156037614377565b336001600160a01b038216141561445557611832565b6002546001600160a01b031633141561446d57611832565b6001600160a01b03811660009081526017602090815260408083203384529091529020546118329060ff166029614377565b8015614518576144c4826001600160a01b0316846001600160a01b031614602a614377565b6001600160a01b0383166000908152601b60205260409020546144eb9060ff16602b614377565b6001600160a01b0383166000908152601e60205260409020546145139060ff1615602c614377565b613714565b6001600160a01b0383166000908152601b602052604090205461453f9060ff16602d614377565b6001600160a01b0383166000908152601e60205260409020546145669060ff16602e614377565b6001600160a01b0382166000908152601e602052604090205461458e9060ff1615602f614377565b6001600160a01b0382166000908152601f60205260409020546137149060ff166030614377565b6000806145c18561183b565b905060006145d08786866136a4565b90506145dc82826142c2565b915060006145ea8884613193565b6001600160a01b0389166000908152602b602052604090205490915061461090826142c2565b6001600160a01b0389166000818152602b60209081526040918290209390935580519182529181018590528082018390529051600080516020615b398339815191529181900360600190a150909695505050505050565b6001600160a01b0381166000818152602080805260408083205481516370a0823160e01b8152306004820152915193949093859391926370a08231926024808301939192829003018186803b1580156146bf57600080fd5b505afa1580156146d3573d6000803e3d6000fd5b505050506040513d60208110156146e957600080fd5b50516001600160a01b038516600090815260208052604090208190559050611b26818361431a565b816147275761472281156027614377565b613a81565b613a81818310156028614377565b6001600160a01b03821660009081526025602052604090205461475890826142c2565b6001600160a01b03831660009081526025602081815260408084208590556024825290922054915261478d9111156034614377565b604080516001600160a01b03841681526020810183905281517faa5649d82f5462be9d19b0f2b31a59b2259950a6076550bac9f3a1c07db9f66d929181900390910190a15050565b6001600160a01b0382166000908152602760205260409020546147f890826142c2565b6001600160a01b03831660008181526027602090815260409182902093909355805191825291810183905281517fd9d4761f75e0d0103b5cbeab941eeb443d7a56a35b5baf2a0787c03f03f4e474929181900390910190a15050565b6001600160a01b038216600090815260276020526040902054614877908261431a565b6001600160a01b03831660008181526027602090815260409182902093909355805191825291810183905281517f34e07158b9db50df5613e591c44ea2ebc82834eff4a4dc3a46e000e608261d68929181900390910190a15050565b6001600160a01b0382166000908152602460205260409020546148f690826142c2565b6001600160a01b03831660008181526024602081815260408084209590955584516370a0823160e01b8152306004820152945192946370a0823193818401939091829003018186803b15801561494b57600080fd5b505afa15801561495f573d6000803e3d6000fd5b505050506040513d602081101561497557600080fd5b50516001600160a01b0384166000908152602460205260409020549091506149a1908210156031614377565b604080516001600160a01b03851681526020810184905281517f976177fbe09a15e5e43f848844963a42b41ef919ef17ff21a17a5421de8f4737929181900390910190a1505050565b604080518082018252601a81527915985d5b1d0e881c1bdbdb105b5bdd5b9d08195e18d95959195960321b6020808301919091526001600160a01b038516600090815260249091529190912054614a429183906154ed565b6001600160a01b03831660009081526024602090815260408083208490556025909152902054614a759110156032614377565b604080516001600160a01b03841681526020810183905281517f112726233fbeaeed0f5b1dba5cb0b2b81883dee49fb35ff99fd98ed9f6d31eb0929181900390910190a15050565b60155462010000900460ff161561437557336000908152601960205260409020546143759060ff166036614377565b6001600160a01b038216600090815260226020526040902054818111614b55576001600160a01b038316600081815260226020908152604080832092909255815192835282018390528051600080516020615aef8339815191529281900390910190a150613a81565b614b5f818361431a565b6001600160a01b0384166000818152602260209081526040918290209390935580519182529181018490528151600080516020615aef833981519152929181900390910190a1505050565b6000816001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b158015614bf957600080fd5b505afa158015614c0d573d6000803e3d6000fd5b505050506040513d6020811015614c2357600080fd5b50516001600160a01b03909216600090815260208052604090209190915550565b600080614c61612710611658614c5a828761431a565b879061422a565b90506000614c6f858361431a565b6001600160a01b0387166000908152602b6020526040902054909150614c9590826142c2565b6001600160a01b0387166000908152602b60205260409020557f47cd9dda0e50ce30bcaaacd0488452b596221c07ac402a581cfae4d3933cac2b8682614cdb828261167e565b604080516001600160a01b039094168452602084019290925282820152519081900360600190a150949350505050565b614d1f6001600160a01b03841682846152dc565b604080516370a0823160e01b815230600482015290516001600160a01b038516916370a08231916024808301926020929190829003018186803b158015614d6557600080fd5b505afa158015614d79573d6000803e3d6000fd5b505050506040513d6020811015614d8f57600080fd5b50516001600160a01b0390931660009081526020805260409020929092555050565b6001600160a01b038216600090815260226020526040902054614dd490826142c2565b6001600160a01b0383166000908152602260209081526040808320939093556023905220548015614e26576001600160a01b038316600090815260226020526040902054614e26908210156033614377565b604080516001600160a01b03851681526020810184905281517f64243679a443432e2293343b77d411ff6144370404618f00ca0d2025d9ca9882929181900390910190a1505050565b6000614e7a876116f2565b6000614e88898989876119e6565b6000818152602a60205260409020805491925090614ea9901515601f614377565b614ebb86826000015410156020614377565b614ecd87826001015410156021614377565b600181015481546004830154600091614eea91611658908b61422a565b6004840154909150614efc908261431a565b6004840155614f0b8b8261532e565b50600080614f1d8d8d8d8d8d8d615547565b8554919350915089146150a3576001600160a01b038c1660009081526028602052604090205460038501558354614f54908a61431a565b8085556001850154614f669190614711565b614f748d8d8d8b600161376c565b50508715614fa157614f978c6120e186600101548661431a90919063ffffffff16565b614fa18c8a614854565b600088614fb657614fb18c613f1b565b614fbf565b614fbf8c612c74565b9050600080516020615a65833981519152868f8f8f8f8f8f88614fe28c8c61431a565b60408051998a526001600160a01b0398891660208b015296881689880152949096166060880152608087019290925260a0860152151560c085015260e084019290925261010083019190915251908190036101200190a18454600186015460028701546003880154600489015460058a0154604080518d81526020810197909752868101959095526060860193909352608085019190915260a084015260c083015251600080516020615a858339815191529181900360e00190a150615205565b87156150bd576150b38c846147d5565b6150bd8c8a614854565b6000886150d2576150cd8c613f1b565b6150db565b6150db8c612c74565b9050600080516020615a65833981519152868f8f8f8f8f8f886150fe8c8c61431a565b60408051998a526001600160a01b0398891660208b015296881689880152949096166060880152608087019290925260a0860152151560c085015260e084019290925261010083019190915251908190036101200190a18454600186015460028701546003880154600489015460058a0154604080518d81526020810197909752868101959095526060860193909352608085019190915260a084015260c0830152517f73af1d417d82c240fdb6d319b34ad884487c6bf2845d98980cc52ad9171cb4559181900360e00190a1506000858152602a602052604081208181556001810182905560028101829055600381018290556004810182905560058101829055600601555b87615214576152148b8a6153e3565b811561525457871561522e5761522e8c6121088e85613193565b600061523a8d83613193565b90506152478d828a614d0b565b95506124a1945050505050565b5060009c9b505050505050505050505050565b6001600160a01b0381166000908152602660209081526040808320546024909252909120541015611832576040805162461bcd60e51b815260206004820152601a6024820152792b30bab63a1d103837b7b620b6b7bab73a101e10313ab33332b960311b604482015290519081900360640190fd5b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b17905261371490849061573c565b604080518082018252601b81527a5661756c743a20696e73756666696369656e74207265736572766560281b6020808301919091526001600160a01b0385166000908152602590915291909120546153879183906154ed565b6001600160a01b03831660008181526025602090815260409182902093909355805191825291810183905281517f533cb5ed32be6a90284e96b5747a1bfc2d38fdb5768a6b5f67ff7d62144ed67b929181900390910190a15050565b6001600160a01b0382166000908152602c60205260409020548082111561542357506001600160a01b0382166000908152602c6020526040812055613a81565b61542d818361431a565b6001600160a01b0384166000908152602c6020526040902055505050565b600081836154d75760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561549c578181015183820152602001615484565b50505050905090810190601f1680156154c95780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816154e357fe5b0495945050505050565b6000818484111561553f5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561549c578181015183820152602001615484565b505050900390565b6000806000615558898989876119e6565b6000818152602a60205260408120805460038201549394509092615580918c918a91906145b5565b90506000806000806155a18d876000015488600201548d8a600601546124e4565b875491955085935091506155b9906116588d8461422a565b9250505060008280156155cc5750600082115b156155fc57506005840180548201905580886155fc5760006155ee8e84613193565b90506155fa8e826149ea565b505b8215801561560a5750600082115b1561564e57600185015461561e908361431a565b6001860155886156425760006156348e84613193565b90506156408e826148d3565b505b60058501805483900390555b8a156156765761565e818c6142c2565b6001860154909150615670908c61431a565b60018601555b84548a141561569957600185015461568f9082906142c2565b6000600187015590505b80848111156156b3576156ac828661431a565b90506156e7565b60018601546156c2908661431a565b600187015589156156e75760006156d98f87613193565b90506156e58f826149ea565b505b60408051888152851515602082015280820185905290517f3ff41bdde87755b687ae83d0221a232b6be51a803330ed9661c1b5d0105e0d8a9181900360600190a1909e909d509b505050505050505050505050565b6060615791826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166157ed9092919063ffffffff16565b805190915015613714578080602001905160208110156157b057600080fd5b50516137145760405162461bcd60e51b815260040180806020018281038252602a815260200180615b0f602a913960400191505060405180910390fd5b6060611b2684846000858561580185615908565b615852576040805162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015290519081900360640190fd5b60006060866001600160a01b031685876040518082805190602001908083835b602083106158915780518252601f199092019160209182019101615872565b6001836020036101000a03801982511681845116808217855250505050505090500191505060006040518083038185875af1925050503d80600081146158f3576040519150601f19603f3d011682016040523d82523d6000602084013e6158f8565b606091505b50915091506124a182828661590e565b3b151590565b6060831561591d575081611ddc565b82511561592d5782518084602001fd5b60405162461bcd60e51b815260206004820181815284516024840152845185939192839260440191908501908083836000831561549c578181015183820152602001615484565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f106159b55782800160ff198235161785556159e2565b828001600101855582156159e2579182015b828111156159e25782358255916020019190600101906159c7565b506159ee929150615a2f565b5090565b6040518060e00160405280600081526020016000815260200160008152602001600081526020016000815260200160008152602001600081525090565b5b808211156159ee5760008155600101615a3056fe5265656e7472616e637947756172643a207265656e7472616e742063616c6c0093d75d64d1f84fc6f430a64fc578bdd4c1e090e90ea2d51773e626d19de56d3025e8a331a7394a9f09862048843323b00bdbada258f524f5ce624a45bf00aabb5661756c743a206c69717569646174696f6e20666565732065786365656420636f6c6c61746572616c536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77e1e812596aac93a06ecc4ca627014d18e30f5c33b825160cc9d5c0ba61e452275361666545524332303a204552433230206f7065726174696f6e20646964206e6f7420737563636565645d0c0019d3d45fadeb74eff9d2c9924d146d000ac6bcf3c28bf0ac3c9baa011aa2646970667358221220df496c6eeb92de9645fec1d1f6921c61616068533eaff090b08dd5144dcbef9e64736f6c634300060c0033

Deployed ByteCode Sourcemap

30558:55514:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;68473:260;;;;;;;;;;;;;;;;-1:-1:-1;68473:260:0;-1:-1:-1;;;;;68473:260:0;;:::i;:::-;;;;;;;;;;;;;;;;31270:71;;;:::i;39663:132::-;;;:::i;65030:312::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;65030:312:0;;;;;;;;:::i;32051:49::-;;;:::i;30922:52::-;;;:::i;31791:27::-;;;:::i;:::-;;;;-1:-1:-1;;;;;31791:27:0;;;;;;;;;;;;;;32577:47;;;:::i;67195:681::-;;;;;;;;;;;;;;;;-1:-1:-1;67195:681:0;-1:-1:-1;;;;;67195:681:0;;:::i;:::-;;31945:41;;;:::i;73339:292::-;;;;;;;;;;;;;;;;-1:-1:-1;73339:292:0;;:::i;32814:53::-;;;:::i;:::-;;;;;;;;;;;;;;;;;;33852:56;;;;;;;;;;;;;;;;-1:-1:-1;33852:56:0;-1:-1:-1;;;;;33852:56:0;;:::i;35655:::-;;;;;;;;;;;;;;;;-1:-1:-1;35655:56:0;-1:-1:-1;;;;;35655:56:0;;:::i;39803:135::-;;;;;;;;;;;;;;;;-1:-1:-1;39803:135:0;;;;:::i;45327:107::-;;;;;;;;;;;;;;;;-1:-1:-1;45327:107:0;-1:-1:-1;;;;;45327:107:0;;:::i;39446:209::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;39446:209:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;39446:209:0;;;;;;;;;;-1:-1:-1;39446:209:0;;-1:-1:-1;39446:209:0;-1:-1:-1;39446:209:0;:::i;64475:162::-;;;;;;;;;;;;;;;;-1:-1:-1;64475:162:0;-1:-1:-1;;;;;64475:162:0;;:::i;63818:307::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;63818:307:0;;;;;;;;:::i;66888:299::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;66888:299:0;;;;;;;;;;;;;;;;;;;;;;;;:::i;40431:135::-;;;;;;;;;;;;;;;;-1:-1:-1;40431:135:0;;;;:::i;32311:49::-;;;:::i;31536:41::-;;;:::i;31495:34::-;;;:::i;75861:284::-;;;;;;;;;;;;;;;;-1:-1:-1;75861:284:0;-1:-1:-1;;;;;75861:284:0;;:::i;43322:1112::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;43322:1112:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;32876:35::-;;;:::i;31584:45::-;;;:::i;41425:1357::-;;;;;;;;;;;;;;;;-1:-1:-1;41425:1357:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;64645:377::-;;;;;;;;;;;;;;;;-1:-1:-1;64645:377:0;;;-1:-1:-1;;;;;64645:377:0;;;;;;;;;;;;:::i;33384:54::-;;;;;;;;;;;;;;;;-1:-1:-1;33384:54:0;-1:-1:-1;;;;;33384:54:0;;:::i;40277:146::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;40277:146:0;;;;;;;;;;:::i;71453:404::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;71453:404:0;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;51637:3652;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;51637:3652:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;31638:30::-;;;:::i;66059:821::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;66059:821:0;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;34661:58;;;;;;;;;;;;;;;;-1:-1:-1;34661:58:0;-1:-1:-1;;;;;34661:58:0;;:::i;31207:50::-;;;:::i;32115:51::-;;;:::i;35544:46::-;;;;;;;;;;;;;;;;-1:-1:-1;35544:46:0;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;68741:418;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;68741:418:0;;;;;;;;;;;;;;;;;;;;;;;;:::i;33578:58::-;;;;;;;;;;;;;;;;-1:-1:-1;33578:58:0;-1:-1:-1;;;;;33578:58:0;;:::i;33005:54::-;;;;;;;;;;;;;;;;-1:-1:-1;33005:54:0;-1:-1:-1;;;;;33005:54:0;;:::i;34259:56::-;;;;;;;;;;;;;;;;-1:-1:-1;34259:56:0;-1:-1:-1;;;;;34259:56:0;;:::i;71865:1097::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;71865:1097:0;;;;;;;;;;;;;;;;;;;;;;;;;:::i;46289:331::-;;;;;;;;;;;;;;;;-1:-1:-1;46289:331:0;-1:-1:-1;;;;;46289:331:0;;:::i;32920:78::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;32920:78:0;;;;;;;;;;:::i;31827:45::-;;;:::i;35788:69::-;;;;;;;;;;;;;;;;-1:-1:-1;35788:69:0;-1:-1:-1;;;;;35788:69:0;;:::i;45442:111::-;;;;;;;;;;;;;;;;-1:-1:-1;45442:111:0;-1:-1:-1;;;;;45442:111:0;;:::i;30981:56::-;;;:::i;47864:1445::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;47864:1445:0;;;;;;;;;;:::i;40968:122::-;;;;;;;;;;;;;;;;-1:-1:-1;40968:122:0;-1:-1:-1;;;;;40968:122:0;;:::i;38718:575::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;38718:575:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;31714:33::-;;;:::i;31993:43::-;;;:::i;40574:151::-;;;;;;;;;;;;;;;;-1:-1:-1;40574:151:0;;;;:::i;46628:1228::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;46628:1228:0;;;;;;;;;;:::i;63625:185::-;;;;;;;;;;;;;;;;-1:-1:-1;63625:185:0;-1:-1:-1;;;;;63625:185:0;;:::i;55297:419::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;55297:419:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;41279:138::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;41279:138:0;;;;;;;;:::i;31158:42::-;;;:::i;33312:65::-;;;;;;;;;;;;;;;;-1:-1:-1;33312:65:0;-1:-1:-1;;;;;33312:65:0;;:::i;42790:524::-;;;;;;;;;;;;;;;;-1:-1:-1;42790:524:0;;;;;;;;;;;;:::i;35720:61::-;;;;;;;;;;;;;;;;-1:-1:-1;35720:61:0;-1:-1:-1;;;;;35720:61:0;;:::i;33247:58::-;;;;;;;;;;;;;;;;-1:-1:-1;33247:58:0;-1:-1:-1;;;;;33247:58:0;;:::i;39301:137::-;;;;;;;;;;;;;;;;-1:-1:-1;39301:137:0;-1:-1:-1;;;;;39301:137:0;;:::i;32765:42::-;;;:::i;49317:2312::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;49317:2312:0;;;;;;;;;;;;;;;;;;;:::i;31044:50::-;;;:::i;32473:49::-;;;:::i;65568:210::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;65568:210:0;;;;;;;;:::i;70169:693::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;70169:693:0;;;;;;;;;;;;;:::i;32421:43::-;;;:::i;32181:47::-;;;:::i;65350:210::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;65350:210:0;;;;;;;;:::i;39946:145::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;39946:145:0;;;;;;;;;;:::i;67884:581::-;;;;;;;;;;;;;;;;-1:-1:-1;67884:581:0;-1:-1:-1;;;;;67884:581:0;;:::i;32681:34::-;;;:::i;33708:57::-;;;;;;;;;;;;;;;;-1:-1:-1;33708:57:0;-1:-1:-1;;;;;33708:57:0;;:::i;33993:59::-;;;;;;;;;;;;;;;;-1:-1:-1;33993:59:0;-1:-1:-1;;;;;33993:59:0;;:::i;31881:48::-;;;:::i;32722:34::-;;;:::i;64133:334::-;;;;;;;;;;;;;;;;-1:-1:-1;64133:334:0;-1:-1:-1;;;;;64133:334:0;;:::i;70870:575::-;;;;;;;;;;;;;;;;-1:-1:-1;70870:575:0;-1:-1:-1;;;;;70870:575:0;;:::i;34413:60::-;;;;;;;;;;;;;;;;-1:-1:-1;34413:60:0;-1:-1:-1;;;;;34413:60:0;;:::i;32529:41::-;;;:::i;35278:67::-;;;;;;;;;;;;;;;;-1:-1:-1;35278:67:0;-1:-1:-1;;;;;35278:67:0;;:::i;74442:1411::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;74442:1411:0;;;;;;;;;;;;;;;;;;;;;;;;;:::i;72970:361::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;72970:361:0;;;;;;;;;;;;;:::i;45989:170::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;45989:170:0;;;;;;;;;;;;;;;;;:::i;40871:89::-;;;;;;;;;;;;;;;;-1:-1:-1;40871:89:0;-1:-1:-1;;;;;40871:89:0;;:::i;40733:130::-;;;;;;;;;;;;;;;;-1:-1:-1;40733:130:0;;:::i;41098:173::-;;;;;;;;;;;;;;;;-1:-1:-1;41098:173:0;;:::i;61766:1659::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;61766:1659:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;45561:348;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;45561:348:0;;;;;;;;:::i;35430:61::-;;;;;;;;;;;;;;;;-1:-1:-1;35430:61:0;-1:-1:-1;;;;;35430:61:0;;:::i;32377:37::-;;;:::i;33181:59::-;;;;;;;;;;;;;;;;-1:-1:-1;33181:59:0;-1:-1:-1;;;;;33181:59:0;;:::i;33445:57::-;;;;;;;;;;;;;;;;-1:-1:-1;33445:57:0;-1:-1:-1;;;;;33445:57:0;;:::i;69331:666::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;69331:666:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;32631:41::-;;;:::i;58982:2726::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;58982:2726:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;32243:52::-;;;:::i;63433:184::-;;;;;;;;;;;;;;;;-1:-1:-1;63433:184:0;-1:-1:-1;;;;;63433:184:0;;:::i;33126:46::-;;;;;;;;;;;;;;;;-1:-1:-1;33126:46:0;;:::i;44442:553::-;;;;;;;;;;;;;;;;-1:-1:-1;44442:553:0;-1:-1:-1;;;;;44442:553:0;;:::i;35134:58::-;;;;;;;;;;;;;;;;-1:-1:-1;35134:58:0;-1:-1:-1;;;;;35134:58:0;;:::i;40099:170::-;;;;;;;;;;;;;;;;-1:-1:-1;40099:170:0;;;;:::i;45003:316::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;45003:316:0;;;;;;;;;;:::i;33066:51::-;;;;;;;;;;;;;;;;-1:-1:-1;33066:51:0;-1:-1:-1;;;;;33066:51:0;;:::i;31756:28::-;;;:::i;31677:30::-;;;:::i;65786:265::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;65786:265:0;;;;;;;;;;;;;:::i;31359:59::-;;;:::i;35866:41::-;;;;;;;;;;;;;;;;-1:-1:-1;35866:41:0;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;68473:260;-1:-1:-1;;;;;68575:19:0;;68534:7;68575:19;;;:11;:19;;;;;;68609:15;68605:34;;68635:1;68628:8;;;;;68605:34;-1:-1:-1;;;;;68658:23:0;;;;;;:15;:23;;;;;;:67;;68714:10;;68658:51;;31030:7;68658:27;:51::i;:::-;:55;;:67::i;:::-;68651:74;;;68473:260;;;;:::o;31270:71::-;-1:-1:-1;;;31270:71:0;:::o;39663:132::-;39760:20;:27;39663:132;:::o;65030:312::-;65121:7;65145:17;65141:36;;-1:-1:-1;65173:1:0;65166:8;;65141:36;65187:13;65203:19;65215:6;65203:11;:19::i;:::-;-1:-1:-1;;;;;65252:21:0;;65233:16;65252:21;;;:13;:21;;;;;;65187:35;;-1:-1:-1;65291:43:0;65319:2;:14;;;65291:23;:12;65187:35;65291:16;:23::i;:43::-;65284:50;;;;65030:312;;;;;:::o;32051:49::-;;;;:::o;30922:52::-;30969:5;30922:52;:::o;31791:27::-;;;-1:-1:-1;;;;;31791:27:0;;:::o;32577:47::-;;;;:::o;67195:681::-;-1:-1:-1;;;;;67270:24:0;;;;;;:16;:24;;;;;;67266:167;;67384:15;;67343:57;;:36;:15;67384;67343:19;:36::i;:::-;:40;;:57::i;:::-;-1:-1:-1;;;;;67316:24:0;;;;;;:16;:24;;;;;:84;67415:7;;67266:167;67478:15;;-1:-1:-1;;;;;67449:24:0;;;;;;:16;:24;;;;;;67497:15;;67449:45;;:24;:28;:45::i;:::-;:63;67445:102;;;67529:7;;67445:102;67559:19;67581:26;67600:6;67581:18;:26::i;:::-;-1:-1:-1;;;;;67651:30:0;;;;;;:22;:30;;;;;;67559:48;;-1:-1:-1;67651:47:0;;67559:48;67651:34;:47::i;:::-;-1:-1:-1;;;;;67618:30:0;;;;;;:22;:30;;;;;:80;67777:15;;67736:57;;:36;:15;67777;67736:19;:36::i;:57::-;-1:-1:-1;;;;;67709:24:0;;;;;;:16;:24;;;;;;;;:84;;;;67837:22;:30;;;;;;;67811:57;;;;;;;;;;;;;;;;;;;;;;67195:681;;;:::o;31945:41::-;;;;:::o;73339:292::-;73404:7;73428:15;73424:34;;-1:-1:-1;73454:1:0;73447:8;;73424:34;73468:19;73490:88;30969:5;73490:62;73505:46;73530:20;;30969:5;73505:24;;:46;;;;:::i;:::-;73490:10;;:14;:62::i;:88::-;73468:110;-1:-1:-1;73596:27:0;:10;73468:110;73596:14;:27::i;32814:53::-;;;;;;;;;:::o;33852:56::-;;;;;;;;;;;;;:::o;35655:::-;;;;;;;;;;;;;:::o;39803:135::-;39879:10;:8;:10::i;:::-;39900:13;:30;;;;;;;-1:-1:-1;;39900:30:0;;;;;;;;;39803:135::o;45327:107::-;45399:10;45383:27;;;;:15;:27;;;;;;;;-1:-1:-1;;;;;45383:36:0;;;;;;;;;;:43;;-1:-1:-1;;45383:43:0;45422:4;45383:43;;;45327:107::o;39446:209::-;39559:15;;;;;-1:-1:-1;;;;;39559:15:0;39545:10;:29;39537:72;;;;;-1:-1:-1;;;39537:72:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;39620:18;;;;:6;:18;;;;;:27;;39641:6;;39620:27;:::i;:::-;;39446:209;;;:::o;64475:162::-;64548:7;64575:54;64589:6;64597:31;64621:6;64597:23;:31::i;:::-;64575:13;:54::i;63818:307::-;63914:7;63934:13;63950:19;63962:6;63950:11;:19::i;:::-;63934:35;-1:-1:-1;63980:24:0;64007:43;63934:35;64007:32;:11;-1:-1:-1;;;64007:15:0;:32::i;:43::-;64104:4;;63980:70;;-1:-1:-1;64068:49:0;;63980:70;;-1:-1:-1;;;;;64104:4:0;64110:6;64068:17;:49::i;66888:299::-;67049:129;;;-1:-1:-1;;;;;;67049:129:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;67039:140;;;;;;66888:299::o;40431:135::-;40507:10;:8;:10::i;:::-;40528:13;:30;;;;;;;-1:-1:-1;;40528:30:0;;;;;;;;;40431:135::o;32311:49::-;;;;:::o;31536:41::-;;;;;;;;;:::o;31495:34::-;;;;;;:::o;75861:284::-;75971:4;;;75964:26;;;-1:-1:-1;;;75964:26:0;;;;75927:7;;;;-1:-1:-1;;;;;75971:4:0;;75964:24;;:26;;;;;;;;;;;75971:4;75964:26;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;75964:26:0;;-1:-1:-1;76005:11:0;76001:30;;76027:1;76020:8;;;;;76001:30;-1:-1:-1;;;;;76058:20:0;;76041:14;76058:20;;;:12;:20;;;;;;76119:17;;76096:41;;:18;76058:20;76107:6;76096:10;:18::i;:41::-;76089:48;75861:284;-1:-1:-1;;;;75861:284:0:o;43322:1112::-;43589:10;:8;:10::i;:::-;-1:-1:-1;;;;;43668:25:0;;;;;;:17;:25;;;;;;;;43663:159;;43734:21;;:28;;43760:1;43734:25;:28::i;:::-;43710:21;:52;43777:20;:33;;;;;;;-1:-1:-1;43777:33:0;;;;;;;;-1:-1:-1;;;;;;43777:33:0;-1:-1:-1;;;;;43777:33:0;;;;;43663:159;43863:17;;-1:-1:-1;;;;;43935:20:0;;43834:26;43935:20;;;:12;:20;;;;;;43912:44;;43863:17;;43912:22;:44::i;:::-;-1:-1:-1;;;;;43969:25:0;;;;;;:17;:25;;;;;;;;:32;;43997:4;-1:-1:-1;;43969:32:0;;;;;;;44012:13;:21;;;;;:38;;;44061:12;:20;;;;;:35;;;44107:20;:28;;;;;:44;;;44162:14;:22;;;;;:39;;;44212:12;:20;;;;;:32;;;;;;;;;;44255:15;:23;;;;;;:38;;;;;;;;;;;43891:65;-1:-1:-1;44326:36:0;43891:65;44061:35;44326:22;:36::i;:::-;44306:17;:56;44407:19;44419:6;44407:11;:19::i;:::-;;43322:1112;;;;;;;;:::o;32876:35::-;;;;:::o;31584:45::-;;;;;;;;;:::o;41425:1357::-;41817:10;:8;:10::i;:::-;41838:53;31254:3;41848:15;:39;;41889:1;41838:9;:53::i;:::-;41902:59;31254:3;41912:21;:45;;41959:1;41902:9;:59::i;:::-;41972:61;31254:3;41982:23;:47;;42031:1;41972:9;:61::i;:::-;42044:57;31254:3;42054:19;:43;;42099:1;42044:9;:57::i;:::-;42112:63;31254:3;42122:25;:49;;42173:1;42112:9;:63::i;:::-;42186:59;31254:3;42196:21;:45;;42243:1;42186:9;:59::i;:::-;42256;-1:-1:-1;;;42266:45:0;;;42313:1;42256:9;:59::i;:::-;42326:14;:32;;;;42369:20;:44;;;;42424:22;:48;;;;42483:18;:40;;;;42534:24;:52;42597:20;:44;42652:17;:38;42701:13;:30;42742:14;:32;;-1:-1:-1;;42742:32:0;;;;;;;;;;41425:1357::o;64645:377::-;64803:4;;64748:7;;;;-1:-1:-1;;;;;64790:17:0;;;64803:4;;64790:17;:60;;-1:-1:-1;;;;;64826:24:0;;;;;;:13;:24;;;;;;64790:60;;;31198:2;64790:60;64896:4;;64768:82;;-1:-1:-1;64861:19:0;;-1:-1:-1;;;;;64883:17:0;;;64896:4;;64883:17;:60;;-1:-1:-1;;;;;64919:24:0;;;;;;:13;:24;;;;;;64883:60;;;31198:2;64883:60;64861:82;;64961:53;65002:11;64996:2;:17;64961:30;64979:11;64973:2;:17;64961:7;:11;;:30;;;;:::i;:53::-;64954:60;;;;64645:377;;;;;;:::o;33384:54::-;;;;;;;;;;;;;;;:::o;40277:146::-;40357:10;:8;:10::i;:::-;-1:-1:-1;;;;;40378:25:0;;;;;;;;:12;:25;;;;;:37;;-1:-1:-1;;40378:37:0;;;;;;;;;;40277:146::o;71453:404::-;71579:4;71585:7;71605:11;71619:64;71634:8;71644:16;71662:11;71675:7;71619:14;:64::i;:::-;71605:78;;71694:24;;:::i;:::-;-1:-1:-1;71721:14:0;;;;:9;:14;;;;;;;;;71694:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;71753:96;;71762:11;;71694:41;;;71813:7;;71753:8;:96::i;:::-;71746:103;;;;;;71453:404;;;;;;;:::o;51637:3652::-;21735:1;22341:7;;:19;;22333:63;;;;;-1:-1:-1;;;22333:63:0;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;22333:63:0;;;;;;;;;;;;;;;21735:1;22474:7;:18;51814:17:::1;::::0;51804:32:::1;::::0;51814:17;;::::1;;;51833:2;51804:9;:32::i;:::-;51847:19;:17;:19::i;:::-;51877:25;51893:8;51877:15;:25::i;:::-;51913:55;51929:16;51947:11;51960:7;51913:15;:55::i;:::-;51979:45;52007:16;51979:27;:45::i;:::-;52037:11;52051:64;52066:8;52076:16;52094:11;52107:7;52051:14;:64::i;:::-;52126:25;52154:14:::0;;;:9:::1;:14;::::0;;;;52037:78;;-1:-1:-1;52197:7:0;:61:::1;;52234:24;52246:11;52234;:24::i;:::-;52197:61;;;52207:24;52219:11;52207;:24::i;:::-;52275:13:::0;;52181:77;;-1:-1:-1;52271:80:0::1;;52310:21;::::0;::::1;:29:::0;;;52271:80:::1;52367:13:::0;;:17;;;;:35:::1;;;52401:1;52388:10;:14;52367:35;52363:218;;;52443:126;52463:11;52476:8;:13;;;52491:8;:21;;;52514:7;52523:5;52530:10;52542:8;:26;;;52443:19;:126::i;:::-;52419:21;::::0;::::1;:150:::0;52363:218:::1;52593:11;52607:90;52626:16;52644:10;52656:8;:13;;;52671:8;:25;;;52607:18;:90::i;:::-;52593:104;;52708:23;52734:29;52746:16;52734:11;:29::i;:::-;52708:55;;52774:26;52803:48;52817:16;52835:15;52803:13;:48::i;:::-;52886:19;::::0;::::1;::::0;52774:77;;-1:-1:-1;52886:43:0::1;::::0;52774:77;52886:23:::1;:43::i;:::-;52864:19;::::0;::::1;:65:::0;;;52940:41:::1;::::0;52950:26;-1:-1:-1;52950:26:0::1;52978:2;52940:9;:41::i;:::-;53016:19;::::0;::::1;::::0;:28:::1;::::0;53040:3;53016:23:::1;:28::i;:::-;52994:19;::::0;::::1;:50:::0;-1:-1:-1;;;;;53083:40:0;::::1;;::::0;;;:22:::1;:40;::::0;;;;;53055:25:::1;::::0;::::1;:68:::0;53150:13;;:29:::1;::::0;53168:10;53150:17:::1;:29::i;:::-;53134:45:::0;;;53219:15:::1;53190:26;::::0;::::1;:44:::0;53247:32:::1;::::0;53257:17;;53276:2:::1;53247:9;:32::i;:::-;53290:53;53308:8;:13;;;53323:8;:19;;;53290:17;:53::i;:::-;53354:75;53374:8;53384:16;53402:11;53415:7;53424:4;53354:19;:75::i;:::-;;;53500:20;53523:43;53537:16;53555:10;53523:13;:43::i;:::-;53602:22;::::0;::::1;::::0;53500:66;;-1:-1:-1;53602:40:0::1;::::0;53500:66;53602:26:::1;:40::i;:::-;53577:22;::::0;::::1;:65:::0;53653:55:::1;53677:16:::0;53695:12;53653:23:::1;:55::i;:::-;53725:7;53721:1261;;;54055:61;54078:16:::0;54096:19:::1;:10:::0;54111:3;54096:14:::1;:19::i;:::-;54055:22;:61::i;:::-;54131:60;54154:16;54172:18;54131:22;:60::i;:::-;54273:54;54293:16;54311:15;54273:19;:54::i;:::-;54508:75;54528:16;54546:36;54560:16;54578:3;54546:13;:36::i;:::-;54508:19;:75::i;:::-;53721:1261;;;-1:-1:-1::0;;;;;54620:29:0;::::1;;::::0;;;:16:::1;:29;::::0;;;;;54616:263:::1;;-1:-1:-1::0;;;;;54675:37:0;::::1;;::::0;;;:24:::1;:37;::::0;;;;:45;;;54616:263:::1;;;54801:62;54832:11;54845:5;54852:10;54801:30;:62::i;:::-;-1:-1:-1::0;;;;;54761:37:0;::::1;;::::0;;;:24:::1;:37;::::0;;;;:102;54616:263:::1;-1:-1:-1::0;;;;;54925:29:0;::::1;;::::0;;;:16:::1;:29;::::0;;;;;:45:::1;::::0;54959:10;54925:33:::1;:45::i;:::-;-1:-1:-1::0;;;;;54893:29:0;::::1;;::::0;;;:16:::1;:29;::::0;;;;:77;53721:1261:::1;54999:115;::::0;;;;;-1:-1:-1;;;;;54999:115:0;;::::1;;::::0;::::1;::::0;;;::::1;::::0;;;;;::::1;::::0;;;;;;;;;;;;;;;;;::::1;;::::0;;;;;;;;;;;;;;;;;;::::1;::::0;;;;;;;::::1;55150:13:::0;;55165:19:::1;::::0;::::1;::::0;55186:21:::1;::::0;::::1;::::0;55209:25:::1;::::0;::::1;::::0;55236:22:::1;::::0;::::1;::::0;55260:20:::1;::::0;::::1;::::0;55130:151:::1;::::0;;;;;::::1;::::0;::::1;::::0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;55130:151:0;;;;;;;::::1;-1:-1:-1::0;;21691:1:0;22653:7;:22;-1:-1:-1;;;;;;;;;;51637:3652:0:o;31638:30::-;;;;;;-1:-1:-1;;;;;31638:30:0;;:::o;66059:821::-;66189:7;66198;66207;66216;66225;66234;66243:4;66249:7;66269:11;66283:64;66298:8;66308:16;66326:11;66339:7;66283:14;:64::i;:::-;66269:78;;66358:24;;:::i;:::-;66385:9;:14;66395:3;66385:14;;;;;;;;;;;66358:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;66410:19;66455:1;66432:8;:20;;;:24;:89;;66500:8;:20;;;66499:21;;66432:89;;;66467:8;:20;;;66432:89;66410:111;;66554:8;:13;;;66587:8;:19;;;66626:8;:21;;;66667:8;:25;;;66712:8;:22;;;66754:11;66809:1;66785:8;:20;;;:25;;66830:8;:26;;;66532:340;;;;;;;;;;;;;;;;;;;66059:821;;;;;;;;;;;;;:::o;34661:58::-;;;;;;;;;;;;;:::o;31207:50::-;31254:3;31207:50;:::o;32115:51::-;;;;:::o;35544:46::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;68741:418::-;68870:7;68890:11;68904:64;68919:8;68929:16;68947:11;68960:7;68904:14;:64::i;:::-;68890:78;;68979:24;;:::i;:::-;-1:-1:-1;69006:14:0;;;;:9;:14;;;;;;;;;68979:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;69031:38;;69041:23;;69066:2;69031:9;:38::i;:::-;69131:19;;;;69087:13;;:64;;69131:19;69087:39;;30969:5;69087:17;:39::i;:64::-;69080:71;68741:418;-1:-1:-1;;;;;;;68741:418:0:o;33578:58::-;;;;;;;;;;;;;:::o;33005:54::-;;;;;;;;;;;;;;;:::o;34259:56::-;;;;;;;;;;;;;:::o;71865:1097::-;72014:4;72020:7;72040:32;72066:1;72050:13;:17;72069:2;72040:9;:32::i;:::-;72083:13;72099:7;:61;;72136:24;72148:11;72136;:24::i;:::-;72099:61;;;72109:24;72121:11;72109;:24::i;:::-;72083:77;;72171:18;72208:5;72192:13;:21;:75;;72243:24;:5;72253:13;72243:9;:24::i;:::-;72192:75;;;72216:24;:13;72234:5;72216:17;:24::i;:::-;72171:96;-1:-1:-1;72278:13:0;72294:40;72320:13;72294:21;:5;72171:96;72294:9;:21::i;:40::-;72278:56;;72347:14;72378:7;72374:139;;;-1:-1:-1;72414:21:0;;;72374:139;;;-1:-1:-1;72480:21:0;;;72374:139;72687:14;72722:37;72745:13;;72722:18;:22;;:37;;;;:::i;:::-;72704:15;:55;:95;;-1:-1:-1;;;;;72766:33:0;;;;;;:20;:33;;;;;;72704:95;;;72762:1;72704:95;72687:112;;72814:9;:65;;;;-1:-1:-1;72862:17:0;:5;72872:6;72862:9;:17::i;:::-;72827:31;:5;30969;72827:9;:31::i;:::-;:52;;72814:65;72810:107;;;72904:1;72896:9;;72810:107;-1:-1:-1;72937:9:0;-1:-1:-1;72948:5:0;-1:-1:-1;;;71865:1097:0;;;;;;;;;:::o;46289:331::-;21735:1;22341:7;;:19;;22333:63;;;;;-1:-1:-1;;;22333:63:0;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;22333:63:0;;;;;;;;;;;;;;;21735:1;22474:7;:18;;;-1:-1:-1;;;;;46384:25:0;::::1;::::0;;:17:::1;:25;::::0;;;;;46374:40:::1;::::0;46384:25:::1;;46411:2;46374:9;:40::i;:::-;46425:19;46447;46459:6;46447:11;:19::i;:::-;46425:41;;46477:30;46501:1;46487:11;:15;46504:2;46477:9;:30::i;:::-;46518:40;46538:6;46546:11;46518:19;:40::i;:::-;46574:38;::::0;;-1:-1:-1;;;;;46574:38:0;::::1;::::0;;::::1;::::0;::::1;::::0;;;;;::::1;::::0;;;;;;;;;::::1;-1:-1:-1::0;;21691:1:0;22653:7;:22;46289:331::o;32920:78::-;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;31827:45::-;;;;:::o;35788:69::-;;;;;;;;;;;;;:::o;45442:111::-;45517:10;45540:5;45501:27;;;:15;:27;;;;;;;;-1:-1:-1;;;;;45501:36:0;;;;;;;;;;:44;;-1:-1:-1;;45501:44:0;;;45442:111::o;30981:56::-;31030:7;30981:56;:::o;47864:1445::-;47957: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;47977::::1;:16;:18::i;:::-;-1:-1:-1::0;;;;;48016:25:0;::::1;;::::0;;;:17:::1;:25;::::0;;;;;48006:40:::1;::::0;48016:25:::1;;48043:2;48006:9;:40::i;:::-;48057:14;:21:::0;;-1:-1:-1;;48057:21:0::1;;;::::0;;48124:4:::1;::::0;48057:21;;48112:17:::1;::::0;-1:-1:-1;;;;;48124:4:0::1;48112:11;:17::i;:::-;48091:38;;48140:29;48163:1;48150:10;:14;48166:2;48140:9;:29::i;:::-;48182:35;48210:6;48182:27;:35::i;:::-;48230:24;48257:39;48277:6;48285:10;48257:19;:39::i;:::-;48230:66;;48307:35;48336:1;48317:16;:20;48339:2;48307:9;:35::i;:::-;48355:39;48375:6;48383:10;48355:19;:39::i;:::-;48405:45;48425:6;48433:16;48405:19;:45::i;:::-;48469:4;::::0;;48463:43:::1;::::0;;-1:-1:-1;;;48463:43:0;;48488:4:::1;48463:43:::0;;::::1;::::0;;;;;;;;;;;-1:-1:-1;;;;;48469:4:0;;::::1;::::0;48463:16:::1;::::0;:43;;;;;48469:4:::1;::::0;48463:43;;;;;;;48469:4;;48463:43;::::1;;::::0;::::1;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;-1:-1:-1::0;;48845:4:0::1;::::0;48825:25:::1;::::0;-1:-1:-1;;;;;;48845:4:0::1;::::0;-1:-1:-1;48825:19:0::1;:25::i;:::-;48863:22;48888:84;48906:6;48914:10;48926:22;;48950:14;;48966:5;48888:17;:84::i;:::-;48863:109;;48983:17;49003:58;49020:6;49028:16;49046:14;49003:16;:58::i;:::-;48983:78;;49072:28;49094:1;49082:9;:13;49097:2;49072:9;:28::i;:::-;49113:42;49126:6;49134:9;49145;49113:12;:42::i;:::-;49173:66;::::0;;-1:-1:-1;;;;;49173:66:0;;::::1;::::0;;;::::1;;::::0;::::1;::::0;;;;;;;;;;;;;;;;;;;;;::::1;::::0;;;;;;;::::1;49252:14;:22:::0;;-1:-1:-1;;49252:22:0::1;::::0;;-1:-1:-1;;22653:22:0;49292:9;47864:1445;-1:-1:-1;;;;;;47864:1445:0:o;40968:122::-;41039:10;:8;:10::i;:::-;41060:9;:22;;-1:-1:-1;;;;;;41060:22:0;-1:-1:-1;;;;;41060:22:0;;;;;;;;;;40968:122::o;38718:575::-;38961:10;:8;:10::i;:::-;38993:13;;;38982:28;;38993:13;;;;38992:14;;38982:9;:28::i;:::-;39037:4;39021:20;;-1:-1:-1;;39021:20:0;;;;;39054:6;:16;;-1:-1:-1;;;;;;39054:16:0;;;-1:-1:-1;;;;;39054:16:0;;;;;;;39081:4;:12;;;;;;;;;;;;;;39104:9;:22;;;;;;;;;;;;;;;;39137:17;:38;;;;39186:17;:38;39235:23;:50;38718:575::o;31714:33::-;;;-1:-1:-1;;;;;31714:33:0;;:::o;31993:43::-;;;;:::o;40574:151::-;40658:10;:8;:10::i;:::-;40679:17;:38;;;;;;;-1:-1:-1;;40679:38:0;;;;;;;;;40574:151::o;46628:1228::-;46720: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;46740::::1;:16;:18::i;:::-;-1:-1:-1::0;;;;;46779:25:0;::::1;;::::0;;;:17:::1;:25;::::0;;;;;46769:40:::1;::::0;46779:25:::1;;46806:2;46769:9;:40::i;:::-;46822:19;46844;46856:6;46844:11;:19::i;:::-;46822:41;;46874:30;46898:1;46884:11;:15;46901:2;46874:9;:30::i;:::-;46917:35;46945:6;46917:27;:35::i;:::-;46965:13;46981:19;46993:6;46981:11;:19::i;:::-;46965:35:::0;-1:-1:-1;47013:18:0::1;47034:43;-1:-1:-1::0;;;47034:22:0::1;:11:::0;46965:35;47034:15:::1;:22::i;:43::-;47139:4;::::0;47013:64;;-1:-1:-1;47101:43:0::1;::::0;47013:64;;47131:6;;-1:-1:-1;;;;;47139:4:0::1;47101:17;:43::i;:::-;47088:56;;47155:29;47178:1;47165:10;:14;47181:2;47155:9;:29::i;:::-;47197:22;47222:83;47240:6;47248:10;47260:22;;47284:14;;47300:4;47222:17;:83::i;:::-;47197:108;;47316:23;47342:53;47359:6;47367:11;47380:14;47342:16;:53::i;:::-;47316:79:::0;-1:-1:-1;47406:18:0::1;47427:47;-1:-1:-1::0;;;47427:26:0::1;47316:79:::0;47447:5;47427:19:::1;:26::i;:47::-;47536:4;::::0;47406:68;;-1:-1:-1;47498:43:0::1;::::0;47406:68;;47528:6;;-1:-1:-1;;;;;47536:4:0::1;47498:17;:43::i;:::-;47485:56;;47554:39;47574:6;47582:10;47554:19;:39::i;:::-;47604:44;47624:6;47632:15;47604:19;:44::i;:::-;47667:4;::::0;;47661:39:::1;::::0;;-1:-1:-1;;;47661:39:0;;-1:-1:-1;;;;;47661:39:0;;::::1;::::0;;::::1;::::0;;;;;;;;;;;;47667:4;;;::::1;::::0;47661:16:::1;::::0;:39;;;;;47667:4:::1;::::0;47661:39;;;;;;;;47667:4;;47661:39;::::1;;::::0;::::1;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;-1:-1:-1::0;;47718:67:0::1;::::0;;-1:-1:-1;;;;;47718:67:0;;::::1;::::0;;;::::1;;::::0;::::1;::::0;;;;;;;;;;;;;;;;;;;;;::::1;::::0;-1:-1:-1;47718:67:0;;;;;;;-1:-1:-1;47718:67:0::1;47798:14;:22:::0;;-1:-1:-1;;47798:22:0::1;::::0;;-1:-1:-1;;22653:22:0;47838:10;46628:1228;-1:-1:-1;;;;;;;;46628:1228:0:o;63625:185::-;63735:9;;63770:15;;63719:83;;;-1:-1:-1;;;63719:83:0;;-1:-1:-1;;;;;63719:83:0;;;;;;;63692:7;63719:83;;;;;;63770:15;;;;63719:83;;;;;;63735:9;63787:14;;;;;;63719:83;;;;;;;;63692:7;;63735:9;;;;;63719:35;;:83;;;;;;;;;;;;;;;63735:9;63719:83;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;63719:83:0;;63625:185;-1:-1:-1;;63625:185:0:o;55297:419::-;55507: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;55527:19:::1;:17;:19::i;:::-;55557:25;55573:8;55557:15;:25::i;:::-;55600:108;55618:8;55628:16;55646:11;55659:16;55677:10;55689:7;55698:9;55600:17;:108::i;:::-;21691:1:::0;22653:7;:22;55593:115;55297:419;-1:-1:-1;;;;;;;;55297:419:0:o;41279:138::-;41357:10;:8;:10::i;:::-;-1:-1:-1;;;;;41378:21:0;;;;;;;:13;:21;;;;;:31;41279:138::o;31158:42::-;31198:2;31158:42;:::o;33312:65::-;;;;;;;;;;;;;:::o;42790:524::-;42922:10;:8;:10::i;:::-;42943:60;31411:7;42953:16;:45;;43000:2;42943:9;:60::i;:::-;43014;31475:5;43024:18;:45;;43071:2;43014:9;:60::i;:::-;43085:66;31475:5;43095:24;:51;;43148:2;43085:9;:66::i;:::-;43162:15;:34;;;;43207:17;:38;43256:23;:50;42790:524::o;35720:61::-;;;;;;;;;;;;;:::o;33247:58::-;;;;;;;;;;;;;:::o;39301:137::-;39375:10;:8;:10::i;:::-;39396:15;:34;;-1:-1:-1;;;;;39396:34:0;;;;;-1:-1:-1;;;;;;39396:34:0;;;;;;;;;39301:137::o;32765:42::-;;;;;;;;;:::o;49317:2312::-;49427: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;49457:13:::1;::::0;49447:28:::1;::::0;49457:13:::1;::::0;::::1;;;49472:2;49447:9;:28::i;:::-;-1:-1:-1::0;;;;;49496:27:0;::::1;;::::0;;;:17:::1;:27;::::0;;;;;49486:42:::1;::::0;49496:27:::1;;49525:2;49486:9;:42::i;:::-;-1:-1:-1::0;;;;;49549:28:0;::::1;;::::0;;;:17:::1;:28;::::0;;;;;49539:43:::1;::::0;49549:28:::1;;49579:2;49539:9;:43::i;:::-;49593:36;49615:9;-1:-1:-1::0;;;;;49603:21:0::1;:8;-1:-1:-1::0;;;;;49603:21:0::1;;;49626:2;49593:9;:36::i;:::-;49642:14;:21:::0;;-1:-1:-1;;49642:21:0::1;;;::::0;;49676:37:::1;49704:8:::0;49676:27:::1;:37::i;:::-;49724:38;49752:9;49724:27;:38::i;:::-;49775:16;49794:21;49806:8;49794:11;:21::i;:::-;49775:40;;49826:27;49847:1;49836:8;:12;49850:2;49826:9;:27::i;:::-;49866:15;49884:21;49896:8;49884:11;:21::i;:::-;49866:39;;49916:16;49935:22;49947:9;49935:11;:22::i;:::-;49916:41:::0;-1:-1:-1;49970:17:0::1;49990:35;49916:41:::0;49990:21:::1;:8:::0;50003:7;49990:12:::1;:21::i;:35::-;49970:55;;50048:49;50066:9;50077:8;50087:9;50048:17;:49::i;:::-;50036:61:::0;-1:-1:-1;50202:18:0::1;50223:42;-1:-1:-1::0;;;50223:21:0::1;:8:::0;50236:7;50223:12:::1;:21::i;:42::-;50329:4;::::0;50202:63;;-1:-1:-1;50289:45:0::1;::::0;50202:63;;50319:8;;-1:-1:-1;;;;;50329:4:0::1;50289:17;:45::i;:::-;-1:-1:-1::0;;;;;50367:22:0;::::1;50347:17;50367:22:::0;;;:12:::1;:22;::::0;;;;;50276:58;;-1:-1:-1;50347:17:0;50367:22:::1;;:49:::0;::::1;;;-1:-1:-1::0;;;;;;50393:23:0;::::1;;::::0;;;:12:::1;:23;::::0;;;;;::::1;;50367:49;50347:69;;50427:22;50475:15:::0;50493:12:::1;:60;;50535:18;;50493:60;;;50508:24;;50493:60;50475:78;;50568:14;50585:12;:52;;50623:14;;50585:52;;;50600:20;;50585:52;50568:69;;50652:24;50679:62;50697:8;50707:10;50719:7;50728:6;50736:4;50679:17;:62::i;:::-;50652:89;;50756:24;50783:64;50801:9;50812:10;50824:7;50833:6;50841:5;50783:17;:64::i;:::-;50756:91;;50957:16;50938;:35;:73;;50995:16;50938:73;;;50976:16;50938:73;50921:90;;22505:1;;;;51033:26;51062:54;51079:9;51090;51101:14;51062:16;:54::i;:::-;51033:83;;51129:41;51149:8;51159:10;51129:19;:41::i;:::-;51181:42;51201:9;51212:10;51181:19;:42::i;:::-;51236:39;51256:8;51266;51236:19;:39::i;:::-;51286:41;51306:9;51317;51286:19;:41::i;:::-;51340:32;51362:9;51340:21;:32::i;:::-;51385:54;51398:9;51409:18;51429:9;51385:12;:54::i;:::-;51457:93;::::0;;-1:-1:-1;;;;;51457:93:0;;::::1;::::0;;;;::::1;;::::0;::::1;::::0;;::::1;::::0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;::::1;::::0;;;;;;;::::1;51563:14;:22:::0;;-1:-1:-1;;51563:22:0::1;::::0;;-1:-1:-1;;22653:22:0;51603:18;49317:2312;-1:-1:-1;;;;;;;;;;;49317:2312:0:o;31044:50::-;-1:-1:-1;;;31044:50:0;:::o;32473:49::-;;;;:::o;65568:210::-;65648:7;65672:15;65668:34;;-1:-1:-1;65698:1:0;65691:8;;65668:34;65719:51;65730:6;65738:10;65750:19;65762:6;65750:11;:19::i;:::-;65719:10;:51::i;70169:693::-;-1:-1:-1;;;;;70326:29:0;;70291:7;70326:29;;;:16;:29;;;;;;;;;70389:24;:37;;;;;;70291:7;70458:25;;;:87;;70517:28;:10;70532:12;70517:14;:28::i;:::-;70458:87;;;70486:28;:12;70503:10;70486:16;:28::i;:::-;70437:108;-1:-1:-1;70556:13:0;70572:38;70597:12;70572:20;:4;70437:108;70572:8;:20::i;:38::-;70556:54;-1:-1:-1;70638:25:0;;;70621:14;70695:20;:4;70704:10;70695:8;:20::i;:::-;70676:39;;70726:15;70744:9;:53;;70778:19;:8;70791:5;70778:12;:19::i;:::-;70744:53;;;70756:19;:8;70769:5;70756:12;:19::i;:::-;70726:71;-1:-1:-1;70817:37:0;70726:71;70817:24;:10;70832:8;70817:14;:24::i;:37::-;70810:44;70169:693;-1:-1:-1;;;;;;;;;;;70169:693:0:o;32421:43::-;;;;;;:::o;32181:47::-;;;;:::o;65350:210::-;65430:7;65454:15;65450:34;;-1:-1:-1;65480:1:0;65473:8;;65450:34;65501:51;65512:6;65520:10;65532:19;65544:6;65532:11;:19::i;39946:145::-;40030:10;:8;:10::i;:::-;-1:-1:-1;;;;;40051:19:0;;;;;;;;:9;:19;;;;;:32;;-1:-1:-1;;40051:32:0;;;;;;;;;;39946:145::o;67884:581::-;68011:15;;-1:-1:-1;;;;;67982:24:0;;67958:7;67982:24;;;:16;:24;;;;;;67958:7;;68030:15;;67982:45;;:28;:45::i;:::-;:63;67978:82;;;-1:-1:-1;68056:1:0;68049:8;;67978:82;68142:15;;-1:-1:-1;;;;;68112:24:0;;68072:17;68112:24;;;:16;:24;;;;;;68072:17;;68092:66;;:45;;:15;;:19;:45::i;:66::-;-1:-1:-1;;;;;68190:19:0;;68169:18;68190:19;;;:11;:19;;;;;;68072:86;;-1:-1:-1;68224:15:0;68220:34;;68250:1;68243:8;;;;;;68220:34;-1:-1:-1;;;;;68295:20:0;;68266:26;68295:20;;;:12;:20;;;;;;;;:66;;68344:17;;68295:66;;;68318:23;;68295:66;-1:-1:-1;;;;;68402:23:0;;;;;;:15;:23;;;;;;68266:95;;-1:-1:-1;68379:78:0;;68446:10;;68379:62;;68431:9;;68379:47;;68266:95;;68379:22;:47::i;:78::-;68372:85;67884:581;-1:-1:-1;;;;;67884:581:0:o;32681:34::-;;;;;;:::o;33708:57::-;;;;;;;;;;;;;:::o;33993:59::-;;;;;;;;;;;;;:::o;31881:48::-;;;;:::o;32722:34::-;;;;;;;;;:::o;64133:334::-;-1:-1:-1;;;;;64227:20:0;;64203:7;64227:20;;;:12;:20;;;;;;;;64223:79;;;-1:-1:-1;;;;;;64271:19:0;;;;;;:11;:19;;;;;;64264:26;;64223:79;-1:-1:-1;;;;;64355:21:0;;64312:18;64355:21;;;:13;:21;;;;;;64333:44;;64347:6;;64333:13;:44::i;:::-;-1:-1:-1;;;;;64435:23:0;;;;;;:15;:23;;;;;;;;;64410:11;:19;;;;;;;64312:65;;-1:-1:-1;64395:64:0;;:35;;64312:65;;64395:14;:35::i;:::-;:39;;:64::i;70870:575::-;-1:-1:-1;;;;;70977:24:0;;70936:4;70977:24;;;:16;:24;;;;;;70936:4;;71016:9;71012:37;;71037:5;71044:1;71029:17;;;;;;;71012:37;71061:17;71081:19;71093:6;71081:11;:19::i;:::-;-1:-1:-1;;;;;71134:32:0;;71111:20;71134:32;;;:24;:32;;;;;;71061:39;;-1:-1:-1;71198:24:0;;;:84;;71255:27;:9;71269:12;71255:13;:27::i;:::-;71198:84;;;71225:27;:12;71242:9;71225:16;:27::i;:::-;71177:105;-1:-1:-1;71293:13:0;71309:38;71334:12;71309:20;:4;71177:105;71309:8;:20::i;:38::-;71375:24;;;;;-1:-1:-1;71293:54:0;;-1:-1:-1;;;;70870:575:0;;;;:::o;34413:60::-;;;;;;;;;;;;;:::o;32529:41::-;;;;:::o;35278:67::-;;;;;;;;;;;;;:::o;74442:1411::-;74627:14;;74602:7;;74627:14;;74622:48;;-1:-1:-1;74652:15:0;74645:22;;74622:48;-1:-1:-1;;;;;74706:19:0;;74682:21;74706:19;;;:11;:19;;;;;;;74757:29;74706:19;74775:10;74757:17;:29::i;:::-;74736:50;;74802:10;74797:119;;74855:13;74842:10;:26;:62;;74875:29;:13;74893:10;74875:17;:29::i;:::-;74842:62;;;74871:1;74842:62;74829:75;;74797:119;74928:20;74951:27;74971:6;74951:19;:27::i;:::-;74928:50;-1:-1:-1;74993:17:0;74989:50;;75021:15;75014:22;;;;;;;74989:50;75051:19;75089:12;75073:13;:28;:96;;75138:31;:12;75155:13;75138:16;:31::i;:::-;75073:96;;;75104:31;:13;75122:12;75104:17;:31::i;:::-;75051:118;;75180:16;75212:12;75199:10;:25;:87;;75258:28;:12;75275:10;75258:16;:28::i;:::-;75199:87;;;75227:28;:10;75242:12;75227:14;:28::i;:::-;75180:106;;75365:11;75354:8;:22;75350:211;;;75393:17;75413:50;75450:12;75413:32;:15;75433:11;75413:19;:32::i;:50::-;75393:70;;75497:15;75485:9;:27;:64;;75519:30;:15;75539:9;75519:19;:30::i;:::-;75485:64;;;75515:1;75485:64;75478:71;;;;;;;;;;75350:211;75573:19;75595:32;75625:1;75595:25;:11;75611:8;75595:15;:25::i;:32::-;75573:54;;75656:12;75642:11;:26;75638:85;;;-1:-1:-1;75699:12:0;75638:85;75733:14;75750:50;75787:12;75750:32;:15;75770:11;75750:19;:32::i;:50::-;75733:67;-1:-1:-1;75818:27:0;:15;75733:67;75818:19;:27::i;:::-;75811:34;74442:1411;-1:-1:-1;;;;;;;;;;;;;74442:1411:0:o;72970:361::-;73072:7;73096:10;73092:29;;-1:-1:-1;73117:1:0;73110:8;;73092:29;-1:-1:-1;;;;;73155:30:0;;73133:19;73155:30;;;:22;:30;;;;;;:53;;73190:17;73155:34;:53::i;:::-;73133:75;-1:-1:-1;73223:16:0;73219:35;;73250:1;73243:8;;;;;73219:35;73273:50;31030:7;73273:22;:5;73283:11;73273:9;:22::i;45989:170::-;46083:10;:8;:10::i;:::-;46104:47;-1:-1:-1;;;;;46104:27:0;;46132:9;46143:7;46104:27;:47::i;:::-;45989:170;;;:::o;40871:89::-;40921:10;:8;:10::i;:::-;40942:3;:10;;-1:-1:-1;;;;;;40942:10:0;-1:-1:-1;;;;;40942:10:0;;;;;;;;;;40871:89::o;40733:130::-;40808:10;:8;:10::i;:::-;40829:11;:26;40733:130::o;41098:173::-;41164:10;:8;:10::i;:::-;41185:41;31140:5;41195:12;:27;41224:1;41185:9;:41::i;:::-;41237:11;:26;41098:173::o;61766:1659::-;61908:7;61917;61937:11;61951:64;61966:8;61976:16;61994:11;62007:7;61951:14;:64::i;:::-;61937:78;;62026:24;;:::i;:::-;-1:-1:-1;62053:14:0;;;;:9;:14;;;;;;;;62026:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;62053:14;;;62114:96;;62123:11;;62026:41;;62174:7;;62114:8;:96::i;:::-;62080:130;;;;62221:18;62242:73;62256:16;62274:8;:13;;;62289:8;:25;;;62242:13;:73::i;:::-;62221:94;;62339:45;62354:29;62369:8;:13;;;62354:14;:29::i;:::-;62339:10;;:14;:45::i;:::-;62326:58;;62402:9;62401:10;:41;;;;;62437:5;62415:8;:19;;;:27;62401:41;62397:168;;;62463:6;62459:58;;;62473:41;;;-1:-1:-1;;;62473:41:0;;;;;;;;;;;;;;;;;;;;;;;;;;;62459:58;62539:1;;-1:-1:-1;62542:10:0;-1:-1:-1;62531:22:0;;-1:-1:-1;;;;62531:22:0;62397:168;62607:19;;;;62642:9;62637:95;;62690:19;;;;:30;;62714:5;62690:23;:30::i;:::-;62668:52;;62637:95;62770:10;62748:19;:32;62744:222;;;62801:6;62797:56;;;62811:39;;;-1:-1:-1;;;62811:39:0;;;;;;;;;;;;;;;;;;;;;;;;;;;62797:56;62931:1;;-1:-1:-1;62934:19:0;-1:-1:-1;62923:31:0;;-1:-1:-1;;;;;62923:31:0;62744:222;63019:17;;63004:33;;:10;;:14;:33::i;:::-;62982:19;:55;62978:192;;;63058:6;63054:68;;;63068:51;;-1:-1:-1;;;63068:51:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;63054:68;-1:-1:-1;63144:1:0;;-1:-1:-1;63147:10:0;-1:-1:-1;63136:22:0;;-1:-1:-1;;;;63136:22:0;62978:192;63225:13;;:39;;30969:5;63225:17;:39::i;:::-;63210:11;;63186:36;;:19;;:23;:36::i;:::-;:78;63182:201;;;63285:6;63281:54;;;63295:37;;;-1:-1:-1;;;63295:37:0;;;;;;;;;;;;-1:-1:-1;;;63295:37:0;;;;;;;;;;;;;;63281:54;-1:-1:-1;63357:1:0;;-1:-1:-1;63360:10:0;-1:-1:-1;63349:22:0;;-1:-1:-1;;;;63349:22:0;63182:201;-1:-1:-1;63403:1:0;;63406:10;;-1:-1:-1;61766:1659:0;-1:-1:-1;;;;;;;;;;61766:1659:0:o;45561:348::-;45637:10;:8;:10::i;:::-;-1:-1:-1;;;;;45681:19:0;;45660:18;45681:19;;;:11;:19;;;;;;45715:20;;;45711:126;;;45752:52;45772:6;45780:23;:7;45792:10;45780:11;:23::i;:::-;45752:19;:52::i;:::-;45819:7;;;45711:126;45849:52;45869:6;45877:23;:10;45892:7;45877:14;:23::i;:::-;45849:19;:52::i;45561:348::-;;;:::o;35430:61::-;;;;;;;;;;;;;:::o;32377:37::-;;;;:::o;33181:59::-;;;;;;;;;;;;;;;:::o;33445:57::-;;;;;;;;;;;;;;;:::o;69331:666::-;69522:7;69543:14;69559:13;69576:72;69585:11;69598:5;69605:13;69620:7;69629:18;69576:8;:72::i;:::-;69542:106;;-1:-1:-1;69542:106:0;-1:-1:-1;69659:16:0;69678:21;:5;69688:10;69678:9;:21::i;:::-;69659:40;;69710:15;69740:7;69736:199;;;69774:9;:53;;69808:19;:8;69821:5;69808:12;:19::i;:::-;69774:53;;;69786:19;:8;69799:5;69786:12;:19::i;:::-;69764:63;;69736:199;;;69870:9;:53;;69904:19;:8;69917:5;69904:12;:19::i;:::-;69870:53;;;69882:19;:8;69895:5;69882:12;:19::i;:::-;69860:63;;69736:199;69952:37;69981:7;69952:24;:10;69967:8;69952:14;:24::i;:37::-;69945:44;69331:666;-1:-1:-1;;;;;;;;;;;;69331:666:0:o;32631:41::-;;;;:::o;58982:2726::-;21735:1;22341:7;;:19;;22333:63;;;;;-1:-1:-1;;;22333:63:0;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;22333:63:0;;;;;;;;;;;;;;;21735:1;22474:7;:18;59147:24:::1;::::0;;;::::1;;;59143:96;;;59211:10;59198:24;::::0;;;:12:::1;:24;::::0;;;;;59188:39:::1;::::0;59198:24:::1;;59224:2;59188:9;:39::i;:::-;59325:15;:23:::0;;-1:-1:-1;;59325:23:0::1;::::0;;59361:45:::1;59389:16:::0;59361:27:::1;:45::i;:::-;59419:11;59433:64;59448:8;59458:16;59476:11;59489:7;59433:14;:64::i;:::-;59419:78;;59508:24;;:::i;:::-;-1:-1:-1::0;59535:14:0::1;::::0;;;:9:::1;:14;::::0;;;;;;;;59508:41;;::::1;::::0;::::1;::::0;;;;;;;::::1;::::0;::::1;::::0;;;::::1;::::0;;;;::::1;::::0;::::1;::::0;;;;;;;;::::1;::::0;::::1;::::0;;;;;::::1;::::0;::::1;::::0;;;;;::::1;::::0;::::1;::::0;;;;;::::1;;::::0;;;;;59560:32:::1;::::0;59570:17;;59589:2:::1;59560:9;:32::i;:::-;59606:24;59632:18:::0;59654:76:::1;59674:8;59684:16;59702:11;59715:7;59724:5;59654:19;:76::i;:::-;59605:125;;;;59741:36;59751:16;59771:1;59751:21;;59774:2;59741:9;:36::i;:::-;59792:16;59812:1;59792:21;59788:293;;;59953:95;59971:8;59981:16;59999:11;60012:1;60015:8;:13;;;60030:7;60039:8;59953:17;:95::i;:::-;;60063:7;;;;;;59788:293;60093:17;60113:43;60127:16;60145:10;60113:13;:43::i;:::-;-1:-1:-1::0;;;;;60199:29:0;::::1;;::::0;;;:11:::1;:29;::::0;;;;;60093:63;;-1:-1:-1;60199:44:0::1;::::0;60093:63;60199:33:::1;:44::i;:::-;-1:-1:-1::0;;;;;60167:29:0;::::1;;::::0;;;:11:::1;:29;::::0;;;;;;;;:76;;;;60259:58;;;;;;;::::1;::::0;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;60259:58:0;;;;;;;::::1;60330:65;60354:16;60372:8;:22;;;60330:23;:65::i;:::-;60410:7;60406:217;;;60493:19;::::0;::::1;::::0;60475:13;;60434:80:::1;::::0;60457:16;;60475:38:::1;::::0;:17:::1;:38::i;:::-;60434:22;:80::i;:::-;60529:82;60549:16;60567:43;60581:16;60599:10;60567:13;:43::i;60529:82::-;60635:17;60655:7;:61;;60692:24;60704:11;60692;:24::i;:::-;60655:61;;;60665:24;60677:11;60665;:24::i;:::-;60635:81;;60732:165;60750:3;60755:8;60765:16;60783:11;60796:7;60805:8;:13;;;60820:8;:19;;;60841:8;:22;;;60865:8;:20;;;60887:9;60732:165;;;;;;;;;-1:-1:-1::0;;;;;60732:165:0::1;;;;;;-1:-1:-1::0;;;;;60732:165:0::1;;;;;;-1:-1:-1::0;;;;;60732:165:0::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;60915:7;60914:8;:44;;;;;60939:8;:19;;;60926:10;:32;60914:44;60910:248;;;61005:19;::::0;::::1;::::0;60975:27:::1;::::0;61005:35:::1;::::0;61029:10;61005:23:::1;:35::i;:::-;60975:65;;61055:91;61075:16;61093:52;61107:16;61125:19;61093:13;:52::i;:::-;61055:19;:91::i;:::-;60910:248;;61175:7;61170:93;;61199:52;61224:11;61237:8;:13;;;61199:24;:52::i;:::-;61282:14;::::0;;;:9:::1;:14;::::0;;;;61275:21;;;::::1;::::0;::::1;::::0;;;::::1;::::0;::::1;::::0;;;::::1;::::0;::::1;::::0;;;::::1;::::0;::::1;::::0;;;::::1;::::0;::::1;::::0;;;::::1;;::::0;61539:17:::1;::::0;61469:89:::1;::::0;61489:16;;61507:50:::1;::::0;61489:16;;61507:13:::1;:50::i;61469:89::-;61569:96;61582:16;61600:50;61614:16;61632:17;;61600:13;:50::i;:::-;61652:12;61569;:96::i;:::-;-1:-1:-1::0;;61678:15:0::1;:22:::0;;-1:-1:-1;;61678:22:0::1;61696:4;61678:22;::::0;;-1:-1:-1;;;;22505:1:0::1;-1:-1:-1::0;;21691:1:0;22653:7;:22;-1:-1:-1;;;58982:2726:0:o;32243:52::-;;;;:::o;63433:184::-;63543:9;;63577:15;;63527:82;;;-1:-1:-1;;;63527:82:0;;-1:-1:-1;;;;;63527:82:0;;;;;;;63543:9;63527:82;;;;63577:15;;;;63527:82;;;;;;63543:9;63594:14;;;;;;63527:82;;;;;;;;63500:7;;63543:9;;;;;63527:35;;:82;;;;;;;;;;;;;;;63543:9;63527:82;;;;;;;;;;33126:46;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;33126:46:0;;-1:-1:-1;33126:46:0;:::o;44442:553::-;44504:10;:8;:10::i;:::-;-1:-1:-1;;;;;44535:25:0;;;;;;:17;:25;;;;;;44525:40;;44535:25;;44562:2;44525:9;:40::i;:::-;-1:-1:-1;;;;;44618:20:0;;;;;;:12;:20;;;;;;44596:17;;:43;;:21;:43::i;:::-;44576:17;:63;-1:-1:-1;;;;;44657:25:0;;;;;;:17;:25;;;;;;;;44650:32;;-1:-1:-1;;44650:32:0;;;;;;44700:13;:21;;;;;44693:28;;;44739:12;:20;;;;;44732:27;;;44777:20;:28;;;;;44770:35;;;44823:14;:22;;;;;44816:29;;;44863:12;:20;;;;;44856:27;;;;;;44901:15;:23;;;;;;44894:30;;;;;;;44959:21;;:28;;44650:32;44959:25;:28::i;:::-;44935:21;:52;-1:-1:-1;44442:553:0:o;35134:58::-;;;;;;;;;;;;;:::o;40099:170::-;40188:10;:8;:10::i;:::-;40209:24;:52;;;;;;;-1:-1:-1;;40209:52:0;;;;;;;;;40099:170::o;45003:316::-;45087:7;45107:10;:8;:10::i;:::-;-1:-1:-1;;;;;45145:19:0;;45128:14;45145:19;;;:11;:19;;;;;;45178:11;45175:29;;45200:1;45193:8;;;;;45175:29;-1:-1:-1;;;;;45214:19:0;;45236:1;45214:19;;;:11;:19;;;;;:23;45248:39;45226:6;45269;45277:9;45248:12;:39::i;33066:51::-;;;;;;;;;;;;;;;:::o;31756:28::-;;;-1:-1:-1;;;;;31756:28:0;;:::o;31677:30::-;;;-1:-1:-1;;;;;31677:30:0;;:::o;65786:265::-;65879:7;65903:15;65899:34;;-1:-1:-1;65929:1:0;65922:8;;65899:34;-1:-1:-1;;;;;65962:21:0;;65943:16;65962:21;;;:13;:21;;;;;;66001:42;66036:6;66001:30;:10;66016:2;:14;;;66001;:30::i;31359:59::-;31411:7;31359:59;:::o;35866:41::-;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;35866:41: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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;85364:84::-;85432:3;;85408:32;;-1:-1:-1;;;;;85432:3:0;85418:10;:17;85437:2;85408:9;:32::i;:::-;85364:84::o;85942:127::-;86042:18;;;;:6;:18;;;;;86030:10;86022:39;;;;-1:-1:-1;;;86022:39:0;;;;;;;;;;;;-1:-1:-1;;86022:39:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;85789:145;85846:11;;85842:33;;85866:7;;85842:33;85885:41;85910:11;;85895;:26;;85923:2;85885:9;:41::i;79647:223::-;79718:10;-1:-1:-1;;;;;79718:22:0;;;79714:39;;;79744:7;;79714:39;79781:6;;-1:-1:-1;;;;;79781:6:0;79767:10;:20;79763:37;;;79791:7;;79763:37;-1:-1:-1;;;;;79820:25:0;;;;;;:15;:25;;;;;;;;79846:10;79820:37;;;;;;;;79810:52;;79820:37;;79859:2;79810:9;:52::i;79878:575::-;79992:7;79988:233;;;80016:46;80046:11;-1:-1:-1;;;;;80026:31:0;:16;-1:-1:-1;;;;;80026:31:0;;80059:2;80016:9;:46::i;:::-;-1:-1:-1;;;;;80087:35:0;;;;;;:17;:35;;;;;;80077:50;;80087:35;;80124:2;80077:9;:50::i;:::-;-1:-1:-1;;;;;80153:30:0;;;;;;:12;:30;;;;;;80142:46;;80153:30;;80152:31;80185:2;80142:9;:46::i;:::-;80203:7;;79988:233;-1:-1:-1;;;;;80243:35:0;;;;;;:17;:35;;;;;;80233:50;;80243:35;;80280:2;80233:9;:50::i;:::-;-1:-1:-1;;;;;80304:30:0;;;;;;:12;:30;;;;;;80294:45;;80304:30;;80336:2;80294:9;:45::i;:::-;-1:-1:-1;;;;;80361:25:0;;;;;;:12;:25;;;;;;80350:41;;80361:25;;80360:26;80388:2;80350:9;:41::i;:::-;-1:-1:-1;;;;;80412:28:0;;;;;;:15;:28;;;;;;80402:43;;80412:28;;80442:2;80402:9;:43::i;80944:532::-;81067:7;81087:14;81104:26;81119:10;81104:14;:26::i;:::-;81087:43;;81143:18;81164:47;81178:6;81186:5;81193:17;81164:13;:47::i;:::-;81143:68;-1:-1:-1;81231:22:0;:6;81143:68;81231:10;:22::i;:::-;81222:31;;81266:17;81286:29;81300:6;81308;81286:13;:29::i;:::-;-1:-1:-1;;;;;81348:19:0;;;;;;:11;:19;;;;;;81266:49;;-1:-1:-1;81348:34:0;;81266:49;81348:23;:34::i;:::-;-1:-1:-1;;;;;81326:19:0;;;;;;:11;:19;;;;;;;;;:56;;;;81400:44;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;81400:44:0;;;;;;;;-1:-1:-1;81462:6:0;;80944:532;-1:-1:-1;;;;;;80944:532:0:o;81484:291::-;-1:-1:-1;;;;;81580:21:0;;81538:7;81580:21;;;:13;:21;;;;;;;;81634:39;;-1:-1:-1;;;81634:39:0;;81667:4;81634:39;;;;;;81538:7;;81580:21;;81538:7;;81580:21;;81634:24;;:39;;;;;81580:13;;81634:39;;;;;81580:21;81634:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;81634:39:0;-1:-1:-1;;;;;81684:21:0;;;;;;81634:39;81684:21;;;;;:35;;;81634:39;-1:-1:-1;81739:28:0;81634:39;81755:11;81739:15;:28::i;79404:235::-;79495:10;79491:95;;79522:31;79532:16;;79550:2;79522:9;:31::i;:::-;79568:7;;79491:95;79596:35;79615:11;79606:5;:20;;79628:2;79596:9;:35::i;83991:282::-;-1:-1:-1;;;;;84102:23:0;;;;;;:15;:23;;;;;;:36;;84130:7;84102:27;:36::i;:::-;-1:-1:-1;;;;;84076:23:0;;;;;;:15;:23;;;;;;;;:62;;;84186:11;:19;;;;;;84159:23;;84149:61;;84159:46;;84207:2;84149:9;:61::i;:::-;84226:39;;;-1:-1:-1;;;;;84226:39:0;;;;;;;;;;;;;;;;;;;;;;;83991:282;;:::o;84530:213::-;-1:-1:-1;;;;;84641:21:0;;;;;;:13;:21;;;;;;:37;;84667:10;84641:25;:37::i;:::-;-1:-1:-1;;;;;84617:21:0;;;;;;:13;:21;;;;;;;;;:61;;;;84694:41;;;;;;;;;;;;;;;;;;;;;;;;84530:213;;:::o;84751:::-;-1:-1:-1;;;;;84862:21:0;;;;;;:13;:21;;;;;;:37;;84888:10;84862:25;:37::i;:::-;-1:-1:-1;;;;;84838:21:0;;;;;;:13;:21;;;;;;;;;:61;;;;84915:41;;;;;;;;;;;;;;;;;;;;;;;;84751:213;;:::o;82200:318::-;-1:-1:-1;;;;;82303:19:0;;;;;;:11;:19;;;;;;:32;;82327:7;82303:23;:32::i;:::-;-1:-1:-1;;;;;82281:19:0;;;;;;:11;:19;;;;;;;;:54;;;;82364:39;;-1:-1:-1;;;82364:39:0;;82397:4;82364:39;;;;;;82281:19;;82364:24;;:39;;;;;;;;;;;82281:19;82364:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;82364:39:0;-1:-1:-1;;;;;82424:19:0;;;;;;:11;82364:39;82424:19;;;;;82364:39;;-1:-1:-1;82414:45:0;;82424:30;-1:-1:-1;82424:30:0;82456:2;82414:9;:45::i;:::-;82475:35;;;-1:-1:-1;;;;;82475:35:0;;;;;;;;;;;;;;;;;;;;;;;82200:318;;;:::o;82526:296::-;82629:62;;;;;;;;;;;-1:-1:-1;;;82629:62:0;;;;;;;;-1:-1:-1;;;;;82629:19:0;;-1:-1:-1;82629:19:0;;;:11;:19;;;;;;;;:62;;82653:7;;82629:23;:62::i;:::-;-1:-1:-1;;;;;82607:19:0;;;;;;:11;:19;;;;;;;;:84;;;82712:15;:23;;;;;;82702:61;;-1:-1:-1;82712:46:0;82760:2;82702:9;:61::i;:::-;82779:35;;;-1:-1:-1;;;;;82779:35:0;;;;;;;;;;;;;;;;;;;;;;;82526:296;;:::o;85548:141::-;85604:13;;;;;;;85600:82;;;85654:10;85644:21;;;;:9;:21;;;;;;85634:36;;85644:21;;85667:2;85634:9;:36::i;83399:584::-;-1:-1:-1;;;;;83496:19:0;;83480:13;83496:19;;;:11;:19;;;;;;83732:16;;;83728:146;;-1:-1:-1;;;;;83765:19:0;;83787:1;83765:19;;;:11;:19;;;;;;;;:23;;;;83808:33;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;83808:33:0;;;;;;;;;83856:7;;;83728:146;83906:18;:5;83916:7;83906:9;:18::i;:::-;-1:-1:-1;;;;;83884:19:0;;;;;;:11;:19;;;;;;;;;:40;;;;83940:35;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;83940:35:0;;;;;;;;;;83399:584;;;:::o;82013:179::-;82077:19;82106:6;-1:-1:-1;;;;;82099:24:0;;82132:4;82099:39;;;;;;;;;;;;;-1:-1:-1;;;;;82099:39:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;82099:39:0;-1:-1:-1;;;;;82149:21:0;;;;;;;82099:39;82149:21;;;;;:35;;;;-1:-1:-1;82013:179:0:o;80461:475::-;80562:7;;80607:80;30969:5;80607:54;80619:41;30969:5;80644:15;80619:24;:41::i;:::-;80607:7;;:11;:54::i;:80::-;80582:105;-1:-1:-1;80698:17:0;80718:27;:7;80582:105;80718:11;:27::i;:::-;-1:-1:-1;;;;;80778:19:0;;;;;;:11;:19;;;;;;80698:47;;-1:-1:-1;80778:34:0;;80698:47;80778:23;:34::i;:::-;-1:-1:-1;;;;;80756:19:0;;;;;;:11;:19;;;;;:56;80828:68;80768:6;80852:9;80863:32;80768:6;80852:9;80863:13;:32::i;:::-;80828:68;;;-1:-1:-1;;;;;80828:68:0;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;80914:14:0;80461:475;-1:-1:-1;;;;80461:475:0:o;81783:222::-;81876:47;-1:-1:-1;;;;;81876:27:0;;81904:9;81915:7;81876:27;:47::i;:::-;81958:39;;;-1:-1:-1;;;81958:39:0;;81991:4;81958:39;;;;;;-1:-1:-1;;;;;81958:24:0;;;;;:39;;;;;;;;;;;;;;:24;:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;81958:39:0;-1:-1:-1;;;;;81934:21:0;;;;;;;81958:39;81934:21;;;;;:63;;;;-1:-1:-1;;81783:222:0:o;83028:363::-;-1:-1:-1;;;;;83131:19:0;;;;;;:11;:19;;;;;;:32;;83155:7;83131:23;:32::i;:::-;-1:-1:-1;;;;;83109:19:0;;;;;;:11;:19;;;;;;;;:54;;;;83198:14;:22;;;;83235:18;;83231:102;;-1:-1:-1;;;;;83280:19:0;;;;;;:11;:19;;;;;;83270:51;;83280:36;-1:-1:-1;83280:36:0;83318:2;83270:9;:51::i;:::-;83348:35;;;-1:-1:-1;;;;;83348:35:0;;;;;;;;;;;;;;;;;;;;;;;83028:363;;;:::o;55724:3250::-;55912:7;55932:45;55960:16;55932:27;:45::i;:::-;55990:11;56004:64;56019:8;56029:16;56047:11;56060:7;56004:14;:64::i;:::-;56079:25;56107:14;;;:9;:14;;;;;56142:13;;55990:78;;-1:-1:-1;56107:14:0;56132:32;;56142:17;;56161:2;56132:9;:32::i;:::-;56175:42;56202:10;56185:8;:13;;;:27;;56214:2;56175:9;:42::i;:::-;56228:54;56261:16;56238:8;:19;;;:39;;56279:2;56228:9;:54::i;:::-;56316:19;;;;56482:13;;56439:22;;;;56295:18;;56439:57;;:38;;56466:10;56439:26;:38::i;:57::-;56532:22;;;;56416:80;;-1:-1:-1;56532:40:0;;56416:80;56532:26;:40::i;:::-;56507:22;;;:65;56583:55;56607:16;56625:12;56583:23;:55::i;:::-;55724:3250;56663:14;56679:22;56705:97;56723:8;56733:16;56751:11;56764:16;56782:10;56794:7;56705:17;:97::i;:::-;56819:13;;56662:140;;-1:-1:-1;56662:140:0;-1:-1:-1;56819:27:0;;56815:1642;;-1:-1:-1;;;;;56891:40:0;;;;;;:22;:40;;;;;;56863:25;;;:68;56962:13;;:29;;56980:10;56962:17;:29::i;:::-;56946:45;;;57041:19;;;;57008:53;;56946:45;57008:17;:53::i;:::-;57076:75;57096:8;57106:16;57124:11;57137:7;57146:4;57076:19;:75::i;:::-;;;57172:7;57168:196;;;57200:77;57223:16;57241:35;57256:8;:19;;;57241:10;:14;;:35;;;;:::i;57200:77::-;57296:52;57319:16;57337:10;57296:22;:52::i;:::-;57380:13;57396:7;:61;;57433:24;57445:11;57433;:24::i;:::-;57396:61;;;57406:24;57418:11;57406;:24::i;:::-;57380:77;-1:-1:-1;;;;;;;;;;;;57494:3:0;57499:8;57509:16;57527:11;57540:16;57558:10;57570:7;57380:77;57586:26;:6;57597:14;57586:10;:26::i;:::-;57477:136;;;;;;-1:-1:-1;;;;;57477:136:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;57653:13;;57668:19;;;;57689:21;;;;57712:25;;;;57739:22;;;;57763:20;;;;57633:151;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;57633:151:0;;;;;;;;56815:1642;;;;57821:7;57817:171;;;57849:52;57872:16;57890:10;57849:22;:52::i;:::-;57920;57943:16;57961:10;57920:22;:52::i;:::-;58004:13;58020:7;:61;;58057:24;58069:11;58057;:24::i;:::-;58020:61;;;58030:24;58042:11;58030;:24::i;:::-;58004:77;-1:-1:-1;;;;;;;;;;;;58118:3:0;58123:8;58133:16;58151:11;58164:16;58182:10;58194:7;58004:77;58210:26;:6;58221:14;58210:10;:26::i;:::-;58101:136;;;;;;-1:-1:-1;;;;;58101:136:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;58276:13;;58291:19;;;;58312:21;;;;58335:25;;;;58362:22;;;;58386:20;;;;58257:150;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;58431:14:0;;;;:9;:14;;;;;58424:21;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;56815:1642;58474:7;58469:90;;58498:49;58523:11;58536:10;58498:24;:49::i;:::-;58575:10;;58571:375;;58606:7;58602:126;;;58634:78;58654:16;58672:39;58686:16;58704:6;58672:13;:39::i;58634:78::-;58742:26;58771:47;58785:16;58803:14;58771:13;:47::i;:::-;58742:76;;58833:61;58846:16;58864:18;58884:9;58833:12;:61::i;:::-;58916:18;-1:-1:-1;58909:25:0;;-1:-1:-1;;;;;58909:25:0;58571:375;-1:-1:-1;58965:1:0;;55724:3250;-1:-1:-1;;;;;;;;;;;;55724:3250:0:o;82830:190::-;-1:-1:-1;;;;;82927:21:0;;;;;;:13;:21;;;;;;;;;82905:11;:19;;;;;;;:43;82901:112;;;82965:36;;;-1:-1:-1;;;82965:36:0;;;;;;;;;;;;-1:-1:-1;;;82965:36:0;;;;;;;;;;;;;;16932:177;17042:58;;;-1:-1:-1;;;;;17042:58:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;17042:58:0;-1:-1:-1;;;17042:58:0;;;17015:86;;17035:5;;17015:19;:86::i;84281:241::-;84392:67;;;;;;;;;;;-1:-1:-1;;;84392:67:0;;;;;;;;-1:-1:-1;;;;;84392:23:0;;-1:-1:-1;84392:23:0;;;:15;:23;;;;;;;;:67;;84420:7;;84392:27;:67::i;:::-;-1:-1:-1;;;;;84366:23:0;;;;;;:15;:23;;;;;;;;;:93;;;;84475:39;;;;;;;;;;;;;;;;;;;;;;;;84281:241;;:::o;84972:292::-;-1:-1:-1;;;;;85073:24:0;;85058:12;85073:24;;;:16;:24;;;;;;85112:14;;;85108:92;;;-1:-1:-1;;;;;;85141:24:0;;85168:1;85141:24;;;:16;:24;;;;;:28;85182:7;;85108:92;85239:17;:4;85248:7;85239:8;:17::i;:::-;-1:-1:-1;;;;;85212:24:0;;;;;;:16;:24;;;;;:44;-1:-1:-1;84972:292: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;76153:3243::-;76322:7;76331;76351:11;76365:64;76380:8;76390:16;76408:11;76421:7;76365:14;:64::i;:::-;76440:25;76468:14;;;:9;:14;;;;;76558:13;;76573:25;;;;76351:78;;-1:-1:-1;76468:14:0;;76509:90;;76528:16;;76546:10;;76558:13;76509:18;:90::i;:::-;76495:104;;76610:14;76635:21;76740:15;76757:13;76774:96;76783:11;76796:8;:13;;;76811:8;:21;;;76834:7;76843:8;:26;;;76774:8;:96::i;:::-;77003:13;;76739:131;;-1:-1:-1;76739:131:0;;-1:-1:-1;76739:131:0;-1:-1:-1;76977:40:0;;:21;:10;76739:131;76977:14;:21::i;:40::-;76961:56;;76153:3243;;77041:14;77103:9;:30;;;;;77132:1;77116:13;:17;77103:30;77099:451;;;-1:-1:-1;77210:20:0;;;;;:44;;77187:67;;77159:13;77358:7;77353:186;;77386:19;77408:46;77422:16;77440:13;77408;:46::i;:::-;77386:68;;77473:50;77493:16;77511:11;77473:19;:50::i;:::-;77353:186;;77567:9;77566:10;:31;;;;;77596:1;77580:13;:17;77566:31;77562:647;;;77636:19;;;;:38;;77660:13;77636:23;:38::i;:::-;77614:19;;;:60;77933:7;77928:186;;77961:19;77983:46;77997:16;78015:13;77983;:46::i;:::-;77961:68;;78048:50;78068:16;78086:11;78048:19;:50::i;:::-;77928:186;;78153:20;;;;;:44;;;78130:67;;77562:647;78332:20;;78328:168;;78378:28;:6;78389:16;78378:10;:28::i;:::-;78443:19;;;;78369:37;;-1:-1:-1;78443:41:0;;78467:16;78443:23;:41::i;:::-;78421:19;;;:63;78328:168;78599:13;;:27;;78595:138;;;78663:19;;;;78652:31;;:6;;:10;:31::i;:::-;78720:1;78698:19;;;:23;78643:40;-1:-1:-1;78595:138:0;78925:6;78946:12;;;78942:345;;;78992:15;:6;79003:3;78992:10;:15::i;:::-;78975:32;;78942:345;;;79062:19;;;;:28;;79086:3;79062:23;:28::i;:::-;79040:19;;;:50;79105:171;;;;79137:17;79157:36;79171:16;79189:3;79157:13;:36::i;:::-;79137:56;;79212:48;79232:16;79250:9;79212:19;:48::i;:::-;79105:171;;79304:40;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;79365:6;;;;-1:-1:-1;76153:3243:0;-1:-1:-1;;;;;;;;;;;;76153:3243:0: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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;11946:195;12049:12;12081:52;12103:6;12111:4;12117:1;12120:12;12049;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;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;;;;;;;;

Swarm Source

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