Overview
S Balance
0 S
S Value
-More Info
Private Name Tags
ContractCreator
Loading...
Loading
Contract Name:
Router
Compiler Version
v0.6.12+commit.27d51765
Contract Source Code (Solidity)
/** *Submitted for verification at SonicScan.org on 2024-12-18 */ // Sources flattened with hardhat v2.12.0 https://hardhat.org // 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/math/SafeMath.sol // 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/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/tokens/interfaces/IWETH.sol // pragma solidity 0.6.12; interface IWETH { function deposit() external payable; function transfer(address to, uint value) external returns (bool); function withdraw(uint) external; } // File contracts/core/interfaces/IVaultUtils.sol // pragma solidity 0.6.12; interface IVaultUtils { function updateCumulativeFundingRate(address _collateralToken, address _indexToken) external returns (bool); function validateIncreasePosition(address _account, address _collateralToken, address _indexToken, uint256 _sizeDelta, bool _isLong) external view; function validateDecreasePosition(address _account, address _collateralToken, address _indexToken, uint256 _collateralDelta, uint256 _sizeDelta, bool _isLong, address _receiver) external view; function validateLiquidation(address _account, address _collateralToken, address _indexToken, bool _isLong, bool _raise) external view returns (uint256, uint256); function getEntryFundingRate(address _collateralToken, address _indexToken, bool _isLong) external view returns (uint256); function getPositionFee(address _account, address _collateralToken, address _indexToken, bool _isLong, uint256 _sizeDelta) external view returns (uint256); function getFundingFee(address _account, address _collateralToken, address _indexToken, bool _isLong, uint256 _size, uint256 _entryFundingRate) external view returns (uint256); function getBuyUsdgFeeBasisPoints(address _token, uint256 _usdgAmount) external view returns (uint256); function getSellUsdgFeeBasisPoints(address _token, uint256 _usdgAmount) external view returns (uint256); function getSwapFeeBasisPoints(address _tokenIn, address _tokenOut, uint256 _usdgAmount) external view returns (uint256); function getFeeBasisPoints(address _token, uint256 _usdgDelta, uint256 _feeBasisPoints, uint256 _taxBasisPoints, bool _increment) external view returns (uint256); } // 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 setVaultUtils(IVaultUtils _vaultUtils) external; 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 getTargetUsdgAmount(address _token) 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 setMaxLeverage(uint256 _maxLeverage) external; 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 setUsdgAmount(address _token, uint256 _amount) external; function setBufferAmount(address _token, uint256 _amount) external; function setMaxGlobalShortSize(address _token, uint256 _amount) external; function setInPrivateLiquidationMode(bool _inPrivateLiquidationMode) external; function setLiquidator(address _liquidator, bool _isActive) external; function setFundingRate(uint256 _fundingInterval, uint256 _fundingRateFactor, uint256 _stableFundingRateFactor) 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 validateLiquidation(address _account, address _collateralToken, address _indexToken, bool _isLong, bool _raise) external view returns (uint256, uint256); function liquidatePosition(address _account, address _collateralToken, address _indexToken, bool _isLong, address _feeReceiver) external; 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 maxGlobalShortSizes(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/IRouter.sol // pragma solidity 0.6.12; interface IRouter { function addPlugin(address _plugin) external; function pluginTransfer(address _token, address _account, address _receiver, uint256 _amount) external; function pluginIncreasePosition(address _account, address _collateralToken, address _indexToken, uint256 _sizeDelta, bool _isLong) external; function pluginDecreasePosition(address _account, address _collateralToken, address _indexToken, uint256 _collateralDelta, uint256 _sizeDelta, bool _isLong, address _receiver) external returns (uint256); function swap(address[] memory _path, uint256 _amountIn, uint256 _minOut, address _receiver) external; } // File contracts/core/Router.sol // pragma solidity 0.6.12; contract Router is IRouter { using SafeMath for uint256; using SafeERC20 for IERC20; using Address for address payable; address public gov; // wrapped BNB / ETH address public weth; address public usdg; address public vault; mapping (address => bool) public plugins; mapping (address => mapping (address => bool)) public approvedPlugins; event Swap(address account, address tokenIn, address tokenOut, uint256 amountIn, uint256 amountOut); modifier onlyGov() { require(msg.sender == gov, "Router: forbidden"); _; } constructor(address _vault, address _usdg, address _weth) public { vault = _vault; usdg = _usdg; weth = _weth; gov = msg.sender; } receive() external payable { require(msg.sender == weth, "Router: invalid sender"); } function setGov(address _gov) external onlyGov { gov = _gov; } function addPlugin(address _plugin) external override onlyGov { plugins[_plugin] = true; } function removePlugin(address _plugin) external onlyGov { plugins[_plugin] = false; } function approvePlugin(address _plugin) external { approvedPlugins[msg.sender][_plugin] = true; } function denyPlugin(address _plugin) external { approvedPlugins[msg.sender][_plugin] = false; } function pluginTransfer(address _token, address _account, address _receiver, uint256 _amount) external override { _validatePlugin(_account); IERC20(_token).safeTransferFrom(_account, _receiver, _amount); } function pluginIncreasePosition(address _account, address _collateralToken, address _indexToken, uint256 _sizeDelta, bool _isLong) external override { _validatePlugin(_account); IVault(vault).increasePosition(_account, _collateralToken, _indexToken, _sizeDelta, _isLong); } function pluginDecreasePosition(address _account, address _collateralToken, address _indexToken, uint256 _collateralDelta, uint256 _sizeDelta, bool _isLong, address _receiver) external override returns (uint256) { _validatePlugin(_account); return IVault(vault).decreasePosition(_account, _collateralToken, _indexToken, _collateralDelta, _sizeDelta, _isLong, _receiver); } function directPoolDeposit(address _token, uint256 _amount) external { IERC20(_token).safeTransferFrom(_sender(), vault, _amount); IVault(vault).directPoolDeposit(_token); } function swap(address[] memory _path, uint256 _amountIn, uint256 _minOut, address _receiver) public override { IERC20(_path[0]).safeTransferFrom(_sender(), vault, _amountIn); uint256 amountOut = _swap(_path, _minOut, _receiver); emit Swap(msg.sender, _path[0], _path[_path.length - 1], _amountIn, amountOut); } function swapETHToTokens(address[] memory _path, uint256 _minOut, address _receiver) external payable { require(_path[0] == weth, "Router: invalid _path"); _transferETHToVault(); uint256 amountOut = _swap(_path, _minOut, _receiver); emit Swap(msg.sender, _path[0], _path[_path.length - 1], msg.value, amountOut); } function swapTokensToETH(address[] memory _path, uint256 _amountIn, uint256 _minOut, address payable _receiver) external { require(_path[_path.length - 1] == weth, "Router: invalid _path"); IERC20(_path[0]).safeTransferFrom(_sender(), vault, _amountIn); uint256 amountOut = _swap(_path, _minOut, address(this)); _transferOutETH(amountOut, _receiver); emit Swap(msg.sender, _path[0], _path[_path.length - 1], _amountIn, amountOut); } function increasePosition(address[] memory _path, address _indexToken, uint256 _amountIn, uint256 _minOut, uint256 _sizeDelta, bool _isLong, uint256 _price) external { if (_amountIn > 0) { IERC20(_path[0]).safeTransferFrom(_sender(), vault, _amountIn); } if (_path.length > 1 && _amountIn > 0) { uint256 amountOut = _swap(_path, _minOut, address(this)); IERC20(_path[_path.length - 1]).safeTransfer(vault, amountOut); } _increasePosition(_path[_path.length - 1], _indexToken, _sizeDelta, _isLong, _price); } function increasePositionETH(address[] memory _path, address _indexToken, uint256 _minOut, uint256 _sizeDelta, bool _isLong, uint256 _price) external payable { require(_path[0] == weth, "Router: invalid _path"); if (msg.value > 0) { _transferETHToVault(); } if (_path.length > 1 && msg.value > 0) { uint256 amountOut = _swap(_path, _minOut, address(this)); IERC20(_path[_path.length - 1]).safeTransfer(vault, amountOut); } _increasePosition(_path[_path.length - 1], _indexToken, _sizeDelta, _isLong, _price); } function decreasePosition(address _collateralToken, address _indexToken, uint256 _collateralDelta, uint256 _sizeDelta, bool _isLong, address _receiver, uint256 _price) external { _decreasePosition(_collateralToken, _indexToken, _collateralDelta, _sizeDelta, _isLong, _receiver, _price); } function decreasePositionETH(address _collateralToken, address _indexToken, uint256 _collateralDelta, uint256 _sizeDelta, bool _isLong, address payable _receiver, uint256 _price) external { uint256 amountOut = _decreasePosition(_collateralToken, _indexToken, _collateralDelta, _sizeDelta, _isLong, address(this), _price); _transferOutETH(amountOut, _receiver); } function decreasePositionAndSwap(address[] memory _path, address _indexToken, uint256 _collateralDelta, uint256 _sizeDelta, bool _isLong, address _receiver, uint256 _price, uint256 _minOut) external { uint256 amount = _decreasePosition(_path[0], _indexToken, _collateralDelta, _sizeDelta, _isLong, address(this), _price); IERC20(_path[0]).safeTransfer(vault, amount); _swap(_path, _minOut, _receiver); } function decreasePositionAndSwapETH(address[] memory _path, address _indexToken, uint256 _collateralDelta, uint256 _sizeDelta, bool _isLong, address payable _receiver, uint256 _price, uint256 _minOut) external { require(_path[_path.length - 1] == weth, "Router: invalid _path"); uint256 amount = _decreasePosition(_path[0], _indexToken, _collateralDelta, _sizeDelta, _isLong, address(this), _price); IERC20(_path[0]).safeTransfer(vault, amount); uint256 amountOut = _swap(_path, _minOut, address(this)); _transferOutETH(amountOut, _receiver); } function _increasePosition(address _collateralToken, address _indexToken, uint256 _sizeDelta, bool _isLong, uint256 _price) private { if (_isLong) { require(IVault(vault).getMaxPrice(_indexToken) <= _price, "Router: mark price higher than limit"); } else { require(IVault(vault).getMinPrice(_indexToken) >= _price, "Router: mark price lower than limit"); } IVault(vault).increasePosition(_sender(), _collateralToken, _indexToken, _sizeDelta, _isLong); } function _decreasePosition(address _collateralToken, address _indexToken, uint256 _collateralDelta, uint256 _sizeDelta, bool _isLong, address _receiver, uint256 _price) private returns (uint256) { if (_isLong) { require(IVault(vault).getMinPrice(_indexToken) >= _price, "Router: mark price lower than limit"); } else { require(IVault(vault).getMaxPrice(_indexToken) <= _price, "Router: mark price higher than limit"); } return IVault(vault).decreasePosition(_sender(), _collateralToken, _indexToken, _collateralDelta, _sizeDelta, _isLong, _receiver); } function _transferETHToVault() private { IWETH(weth).deposit{value: msg.value}(); IERC20(weth).safeTransfer(vault, msg.value); } function _transferOutETH(uint256 _amountOut, address payable _receiver) private { IWETH(weth).withdraw(_amountOut); _receiver.sendValue(_amountOut); } function _swap(address[] memory _path, uint256 _minOut, address _receiver) private returns (uint256) { if (_path.length == 2) { return _vaultSwap(_path[0], _path[1], _minOut, _receiver); } if (_path.length == 3) { uint256 midOut = _vaultSwap(_path[0], _path[1], 0, address(this)); IERC20(_path[1]).safeTransfer(vault, midOut); return _vaultSwap(_path[1], _path[2], _minOut, _receiver); } revert("Router: invalid _path.length"); } function _vaultSwap(address _tokenIn, address _tokenOut, uint256 _minOut, address _receiver) private returns (uint256) { uint256 amountOut; if (_tokenOut == usdg) { // buyUSDG amountOut = IVault(vault).buyUSDG(_tokenIn, _receiver); } else if (_tokenIn == usdg) { // sellUSDG amountOut = IVault(vault).sellUSDG(_tokenOut, _receiver); } else { // swap amountOut = IVault(vault).swap(_tokenIn, _tokenOut, _receiver); } require(amountOut >= _minOut, "Router: insufficient amountOut"); return amountOut; } function _sender() private view returns (address) { return msg.sender; } function _validatePlugin(address _account) private view { require(plugins[msg.sender], "Router: invalid plugin"); require(approvedPlugins[_account][msg.sender], "Router: plugin not approved"); } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address","name":"_vault","type":"address"},{"internalType":"address","name":"_usdg","type":"address"},{"internalType":"address","name":"_weth","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"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"}],"name":"Swap","type":"event"},{"inputs":[{"internalType":"address","name":"_plugin","type":"address"}],"name":"addPlugin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_plugin","type":"address"}],"name":"approvePlugin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"}],"name":"approvedPlugins","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"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"},{"internalType":"uint256","name":"_price","type":"uint256"}],"name":"decreasePosition","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_path","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"},{"internalType":"uint256","name":"_price","type":"uint256"},{"internalType":"uint256","name":"_minOut","type":"uint256"}],"name":"decreasePositionAndSwap","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_path","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 payable","name":"_receiver","type":"address"},{"internalType":"uint256","name":"_price","type":"uint256"},{"internalType":"uint256","name":"_minOut","type":"uint256"}],"name":"decreasePositionAndSwapETH","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"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 payable","name":"_receiver","type":"address"},{"internalType":"uint256","name":"_price","type":"uint256"}],"name":"decreasePositionETH","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_plugin","type":"address"}],"name":"denyPlugin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"directPoolDeposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"gov","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"_path","type":"address[]"},{"internalType":"address","name":"_indexToken","type":"address"},{"internalType":"uint256","name":"_amountIn","type":"uint256"},{"internalType":"uint256","name":"_minOut","type":"uint256"},{"internalType":"uint256","name":"_sizeDelta","type":"uint256"},{"internalType":"bool","name":"_isLong","type":"bool"},{"internalType":"uint256","name":"_price","type":"uint256"}],"name":"increasePosition","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_path","type":"address[]"},{"internalType":"address","name":"_indexToken","type":"address"},{"internalType":"uint256","name":"_minOut","type":"uint256"},{"internalType":"uint256","name":"_sizeDelta","type":"uint256"},{"internalType":"bool","name":"_isLong","type":"bool"},{"internalType":"uint256","name":"_price","type":"uint256"}],"name":"increasePositionETH","outputs":[],"stateMutability":"payable","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":"pluginDecreasePosition","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","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":"pluginIncreasePosition","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"address","name":"_account","type":"address"},{"internalType":"address","name":"_receiver","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"pluginTransfer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"plugins","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_plugin","type":"address"}],"name":"removePlugin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_gov","type":"address"}],"name":"setGov","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_path","type":"address[]"},{"internalType":"uint256","name":"_amountIn","type":"uint256"},{"internalType":"uint256","name":"_minOut","type":"uint256"},{"internalType":"address","name":"_receiver","type":"address"}],"name":"swap","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_path","type":"address[]"},{"internalType":"uint256","name":"_minOut","type":"uint256"},{"internalType":"address","name":"_receiver","type":"address"}],"name":"swapETHToTokens","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_path","type":"address[]"},{"internalType":"uint256","name":"_amountIn","type":"uint256"},{"internalType":"uint256","name":"_minOut","type":"uint256"},{"internalType":"address payable","name":"_receiver","type":"address"}],"name":"swapTokensToETH","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"usdg","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"vault","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"weth","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}]
Contract Creation Code
608060405234801561001057600080fd5b506040516124c83803806124c88339818101604052606081101561003357600080fd5b5080516020820151604090920151600380546001600160a01b039384166001600160a01b03199182161790915560028054948416948216949094179093556001805492909116918316919091179055600080549091163317905561242c8061009c6000396000f3fe60806040526004361061014f5760003560e01c806390205d8c116100b6578063b7ddc9921161006f578063b7ddc9921461099b578063cedd437514610a71578063cfad57a214610aa4578063d8867fc814610ad7578063f5b91b7b14610b0a578063fbfa77cf14610b1f576101ae565b806390205d8c1461072357806390b64ad314610782578063956f285e146107bb578063a4d95b64146107f6578063abe68eaa14610829578063b32755de146108d8576101ae565b806338c74dd91161010857806338c74dd9146104935780633fc8cef3146104c6578063430ed37c146104db5780634b12e6431461053a5780635fc8500e146105815780636023e96614610661576101ae565b806312d43a51146101b35780631b827878146101e45780631f1dd1761461022d5780632662166b1461027e5780632d4ba6a7146102f15780633039e37f146103b3576101ae565b366101ae576001546001600160a01b031633146101ac576040805162461bcd60e51b81526020600482015260166024820152752937baba32b91d1034b73b30b634b21039b2b73232b960511b604482015290519081900360640190fd5b005b600080fd5b3480156101bf57600080fd5b506101c8610b34565b604080516001600160a01b039092168252519081900360200190f35b3480156101f057600080fd5b506101ac6004803603608081101561020757600080fd5b506001600160a01b03813581169160208101358216916040820135169060600135610b43565b34801561023957600080fd5b506101ac600480360360a081101561025057600080fd5b506001600160a01b038135811691602081013582169160408201351690606081013590608001351515610b67565b34801561028a57600080fd5b506102df600480360360e08110156102a157600080fd5b506001600160a01b0381358116916020810135821691604082013581169160608101359160808201359160a081013515159160c09091013516610bfc565b60408051918252519081900360200190f35b3480156102fd57600080fd5b506101ac6004803603608081101561031457600080fd5b810190602081018135600160201b81111561032e57600080fd5b82018360208201111561034057600080fd5b803590602001918460208302840111600160201b8311171561036157600080fd5b91908080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525092955050823593505050602081013590604001356001600160a01b0316610cbc565b3480156103bf57600080fd5b506101ac60048036036101008110156103d757600080fd5b810190602081018135600160201b8111156103f157600080fd5b82018360208201111561040357600080fd5b803590602001918460208302840111600160201b8311171561042457600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550505081356001600160a01b0390811693506020830135926040810135925060608101351515916080820135169060a08101359060c00135610e3f565b34801561049f57600080fd5b506101ac600480360360208110156104b657600080fd5b50356001600160a01b0316610f4e565b3480156104d257600080fd5b506101c8610f7f565b3480156104e757600080fd5b506101ac600480360360e08110156104fe57600080fd5b506001600160a01b0381358116916020810135821691604082013591606081013591608082013515159160a08101359091169060c00135610f8e565b34801561054657600080fd5b5061056d6004803603602081101561055d57600080fd5b50356001600160a01b0316610fb5565b604080519115158252519081900360200190f35b34801561058d57600080fd5b506101ac60048036036101008110156105a557600080fd5b810190602081018135600160201b8111156105bf57600080fd5b8201836020820111156105d157600080fd5b803590602001918460208302840111600160201b831117156105f257600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550505081356001600160a01b0390811693506020830135926040810135925060608101351515916080820135169060a08101359060c00135610fca565b34801561066d57600080fd5b506101ac6004803603608081101561068457600080fd5b810190602081018135600160201b81111561069e57600080fd5b8201836020820111156106b057600080fd5b803590602001918460208302840111600160201b831117156106d157600080fd5b91908080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525092955050823593505050602081013590604001356001600160a01b0316611010565b34801561072f57600080fd5b506101ac600480360360e081101561074657600080fd5b506001600160a01b0381358116916020810135821691604082013591606081013591608082013515159160a08101359091169060c00135611059565b34801561078e57600080fd5b506101ac600480360360408110156107a557600080fd5b506001600160a01b038135169060200135611068565b3480156107c757600080fd5b5061056d600480360360408110156107de57600080fd5b506001600160a01b03813581169160200135166110f4565b34801561080257600080fd5b506101ac6004803603602081101561081957600080fd5b50356001600160a01b0316611114565b6101ac6004803603606081101561083f57600080fd5b810190602081018135600160201b81111561085957600080fd5b82018360208201111561086b57600080fd5b803590602001918460208302840111600160201b8311171561088c57600080fd5b91908080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525092955050823593505050602001356001600160a01b0316611188565b6101ac600480360360c08110156108ee57600080fd5b810190602081018135600160201b81111561090857600080fd5b82018360208201111561091a57600080fd5b803590602001918460208302840111600160201b8311171561093b57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550506001600160a01b03833516935050506020810135906040810135906060810135151590608001356112b9565b3480156109a757600080fd5b506101ac600480360360e08110156109be57600080fd5b810190602081018135600160201b8111156109d857600080fd5b8201836020820111156109ea57600080fd5b803590602001918460208302840111600160201b83111715610a0b57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550506001600160a01b0383351693505050602081013590604081013590606081013590608081013515159060a001356113b3565b348015610a7d57600080fd5b506101ac60048036036020811015610a9457600080fd5b50356001600160a01b0316611460565b348015610ab057600080fd5b506101ac60048036036020811015610ac757600080fd5b50356001600160a01b031661148e565b348015610ae357600080fd5b506101ac60048036036020811015610afa57600080fd5b50356001600160a01b0316611503565b348015610b1657600080fd5b506101c861157a565b348015610b2b57600080fd5b506101c8611589565b6000546001600160a01b031681565b610b4c83611598565b610b616001600160a01b038516848484611670565b50505050565b610b7085611598565b600354604080516348d91abf60e01b81526001600160a01b03888116600483015287811660248301528681166044830152606482018690528415156084830152915191909216916348d91abf9160a480830192600092919082900301818387803b158015610bdd57600080fd5b505af1158015610bf1573d6000803e3d6000fd5b505050505050505050565b6000610c0788611598565b6003546040805163082a084960e41b81526001600160a01b038b811660048301528a811660248301528981166044830152606482018990526084820188905286151560a483015285811660c4830152915191909216916382a084909160e48083019260209291908290030181600087803b158015610c8457600080fd5b505af1158015610c98573d6000803e3d6000fd5b505050506040513d6020811015610cae57600080fd5b505198975050505050505050565b60015484516001600160a01b039091169085906000198101908110610cdd57fe5b60200260200101516001600160a01b031614610d38576040805162461bcd60e51b81526020600482015260156024820152740a4deeae8cae47440d2dcecc2d8d2c840bee0c2e8d605b1b604482015290519081900360640190fd5b610d82610d436116ca565b60035486516001600160a01b039091169086908890600090610d6157fe5b60200260200101516001600160a01b0316611670909392919063ffffffff16565b6000610d8f8584306116ce565b9050610d9b818361180f565b7fcd3829a3813dc3cdd188fd3d01dcf3268c16be2fdd2dd21d0665418816e460623386600081518110610dca57fe5b602002602001015187600189510381518110610de257fe5b6020026020010151878560405180866001600160a01b03168152602001856001600160a01b03168152602001846001600160a01b031681526020018381526020018281526020019550505050505060405180910390a15050505050565b60015488516001600160a01b039091169089906000198101908110610e6057fe5b60200260200101516001600160a01b031614610ebb576040805162461bcd60e51b81526020600482015260156024820152740a4deeae8cae47440d2dcecc2d8d2c840bee0c2e8d605b1b604482015290519081900360640190fd5b6000610ee089600081518110610ecd57fe5b602002602001015189898989308961188c565b9050610f29600360009054906101000a90046001600160a01b0316828b600081518110610f0957fe5b60200260200101516001600160a01b0316611a999092919063ffffffff16565b6000610f368a84306116ce565b9050610f42818661180f565b50505050505050505050565b3360009081526005602090815260408083206001600160a01b0394909416835292905220805460ff19166001179055565b6001546001600160a01b031681565b6000610f9f8888888888308861188c565b9050610fab818461180f565b5050505050505050565b60046020526000908152604090205460ff1681565b6000610fdc89600081518110610ecd57fe5b9050611005600360009054906101000a90046001600160a01b0316828b600081518110610f0957fe5b610f428983866116ce565b61101b610d436116ca565b60006110288584846116ce565b90507fcd3829a3813dc3cdd188fd3d01dcf3268c16be2fdd2dd21d0665418816e460623386600081518110610dca57fe5b610fab8787878787878761188c565b61108a6110736116ca565b6003546001600160a01b0385811692911684611670565b60035460408051635f7bc11960e01b81526001600160a01b03858116600483015291519190921691635f7bc11991602480830192600092919082900301818387803b1580156110d857600080fd5b505af11580156110ec573d6000803e3d6000fd5b505050505050565b600560209081526000928352604080842090915290825290205460ff1681565b6000546001600160a01b03163314611167576040805162461bcd60e51b81526020600482015260116024820152702937baba32b91d103337b93134b23232b760791b604482015290519081900360640190fd5b6001600160a01b03166000908152600460205260409020805460ff19169055565b60015483516001600160a01b039091169084906000906111a457fe5b60200260200101516001600160a01b0316146111ff576040805162461bcd60e51b81526020600482015260156024820152740a4deeae8cae47440d2dcecc2d8d2c840bee0c2e8d605b1b604482015290519081900360640190fd5b611207611af0565b60006112148484846116ce565b90507fcd3829a3813dc3cdd188fd3d01dcf3268c16be2fdd2dd21d0665418816e46062338560008151811061124557fe5b60200260200101518660018851038151811061125d57fe5b6020026020010151348560405180866001600160a01b03168152602001856001600160a01b03168152602001846001600160a01b031681526020018381526020018281526020019550505050505060405180910390a150505050565b60015486516001600160a01b039091169087906000906112d557fe5b60200260200101516001600160a01b031614611330576040805162461bcd60e51b81526020600482015260156024820152740a4deeae8cae47440d2dcecc2d8d2c840bee0c2e8d605b1b604482015290519081900360640190fd5b341561133e5761133e611af0565b6001865111801561134f5750600034115b1561138f5760006113618786306116ce565b905061138d600360009054906101000a90046001600160a01b0316828960018b510381518110610f0957fe5b505b6110ec866001885103815181106113a257fe5b602002602001015186858585611b79565b84156113e2576113e26113c46116ca565b60035489516001600160a01b039091169088908b90600090610d6157fe5b600187511180156113f35750600085115b156114335760006114058886306116ce565b9050611431600360009054906101000a90046001600160a01b0316828a60018c510381518110610f0957fe5b505b6114578760018951038151811061144657fe5b602002602001015187858585611b79565b50505050505050565b3360009081526005602090815260408083206001600160a01b0394909416835292905220805460ff19169055565b6000546001600160a01b031633146114e1576040805162461bcd60e51b81526020600482015260116024820152702937baba32b91d103337b93134b23232b760791b604482015290519081900360640190fd5b600080546001600160a01b0319166001600160a01b0392909216919091179055565b6000546001600160a01b03163314611556576040805162461bcd60e51b81526020600482015260116024820152702937baba32b91d103337b93134b23232b760791b604482015290519081900360640190fd5b6001600160a01b03166000908152600460205260409020805460ff19166001179055565b6002546001600160a01b031681565b6003546001600160a01b031681565b3360009081526004602052604090205460ff166115f5576040805162461bcd60e51b81526020600482015260166024820152752937baba32b91d1034b73b30b634b21038363ab3b4b760511b604482015290519081900360640190fd5b6001600160a01b038116600090815260056020908152604080832033845290915290205460ff1661166d576040805162461bcd60e51b815260206004820152601b60248201527f526f757465723a20706c7567696e206e6f7420617070726f7665640000000000604482015290519081900360640190fd5b50565b604080516001600160a01b0380861660248301528416604482015260648082018490528251808303909101815260849091019091526020810180516001600160e01b03166323b872dd60e01b179052610b61908590611d74565b3390565b60008351600214156117155761170e846000815181106116ea57fe5b6020026020010151856001815181106116ff57fe5b60200260200101518585611e25565b9050611808565b8351600314156117bb5760006117568560008151811061173157fe5b60200260200101518660018151811061174657fe5b6020026020010151600030611e25565b905061177f600360009054906101000a90046001600160a01b03168287600181518110610f0957fe5b6117b38560018151811061178f57fe5b6020026020010151866002815181106117a457fe5b60200260200101518686611e25565b915050611808565b6040805162461bcd60e51b815260206004820152601c60248201527f526f757465723a20696e76616c6964205f706174682e6c656e67746800000000604482015290519081900360640190fd5b9392505050565b60015460408051632e1a7d4d60e01b81526004810185905290516001600160a01b0390921691632e1a7d4d9160248082019260009290919082900301818387803b15801561185c57600080fd5b505af1158015611870573d6000803e3d6000fd5b50611888925050506001600160a01b03821683612023565b5050565b6000831561195257600354604080516340d3096b60e11b81526001600160a01b038a811660048301529151859392909216916381a612d691602480820192602092909190829003018186803b1580156118e457600080fd5b505afa1580156118f8573d6000803e3d6000fd5b505050506040513d602081101561190e57600080fd5b5051101561194d5760405162461bcd60e51b81526004018080602001828103825260238152602001806123866023913960400191505060405180910390fd5b611a0b565b60035460408051637092736960e11b81526001600160a01b038a8116600483015291518593929092169163e124e6d291602480820192602092909190829003018186803b1580156119a257600080fd5b505afa1580156119b6573d6000803e3d6000fd5b505050506040513d60208110156119cc57600080fd5b50511115611a0b5760405162461bcd60e51b81526004018080602001828103825260248152602001806123d36024913960400191505060405180910390fd5b6003546001600160a01b03166382a08490611a246116ca565b604080516001600160e01b031960e085901b1681526001600160a01b039283166004820152828d166024820152828c166044820152606481018b9052608481018a905288151560a482015291871660c48301525160e48083019260209291908290030181600087803b158015610c8457600080fd5b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b179052611aeb908490611d74565b505050565b600160009054906101000a90046001600160a01b03166001600160a01b031663d0e30db0346040518263ffffffff1660e01b81526004016000604051808303818588803b158015611b4057600080fd5b505af1158015611b54573d6000803e3d6000fd5b5050600354600154611b7794506001600160a01b03908116935016905034611a99565b565b8115611c3d5760035460408051637092736960e11b81526001600160a01b03878116600483015291518493929092169163e124e6d291602480820192602092909190829003018186803b158015611bcf57600080fd5b505afa158015611be3573d6000803e3d6000fd5b505050506040513d6020811015611bf957600080fd5b50511115611c385760405162461bcd60e51b81526004018080602001828103825260248152602001806123d36024913960400191505060405180910390fd5b611cf6565b600354604080516340d3096b60e11b81526001600160a01b0387811660048301529151849392909216916381a612d691602480820192602092909190829003018186803b158015611c8d57600080fd5b505afa158015611ca1573d6000803e3d6000fd5b505050506040513d6020811015611cb757600080fd5b50511015611cf65760405162461bcd60e51b81526004018080602001828103825260238152602001806123866023913960400191505060405180910390fd5b6003546001600160a01b03166348d91abf611d0f6116ca565b604080516001600160e01b031960e085901b1681526001600160a01b039283166004820152828a16602482015291881660448301526064820187905285151560848301525160a480830192600092919082900301818387803b158015610bdd57600080fd5b6060611dc9826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166121089092919063ffffffff16565b805190915015611aeb57808060200190516020811015611de857600080fd5b5051611aeb5760405162461bcd60e51b815260040180806020018281038252602a8152602001806123a9602a913960400191505060405180910390fd5b60025460009081906001600160a01b0386811691161415611eca576003546040805163817bb85760e01b81526001600160a01b03898116600483015286811660248301529151919092169163817bb8579160448083019260209291908290030181600087803b158015611e9757600080fd5b505af1158015611eab573d6000803e3d6000fd5b505050506040513d6020811015611ec157600080fd5b50519050611fc5565b6002546001600160a01b0387811691161415611f375760035460408051630711e61960e41b81526001600160a01b03888116600483015286811660248301529151919092169163711e61909160448083019260209291908290030181600087803b158015611e9757600080fd5b60035460408051634998b10960e11b81526001600160a01b038981166004830152888116602483015286811660448301529151919092169163933162129160648083019260209291908290030181600087803b158015611f9657600080fd5b505af1158015611faa573d6000803e3d6000fd5b505050506040513d6020811015611fc057600080fd5b505190505b8381101561201a576040805162461bcd60e51b815260206004820152601e60248201527f526f757465723a20696e73756666696369656e7420616d6f756e744f75740000604482015290519081900360640190fd5b95945050505050565b80471015612078576040805162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e6365000000604482015290519081900360640190fd5b6040516000906001600160a01b0384169083908381818185875af1925050503d80600081146120c3576040519150601f19603f3d011682016040523d82523d6000602084013e6120c8565b606091505b5050905080611aeb5760405162461bcd60e51b815260040180806020018281038252603a815260200180612326603a913960400191505060405180910390fd5b6060612117848460008561211f565b949350505050565b6060824710156121605760405162461bcd60e51b81526004018080602001828103825260268152602001806123606026913960400191505060405180910390fd5b6121698561227b565b6121ba576040805162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015290519081900360640190fd5b60006060866001600160a01b031685876040518082805190602001908083835b602083106121f95780518252601f1990920191602091820191016121da565b6001836020036101000a03801982511681845116808217855250505050505090500191505060006040518083038185875af1925050503d806000811461225b576040519150601f19603f3d011682016040523d82523d6000602084013e612260565b606091505b5091509150612270828286612281565b979650505050505050565b3b151590565b60608315612290575081611808565b8251156122a05782518084602001fd5b8160405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156122ea5781810151838201526020016122d2565b50505050905090810190601f1680156123175780820380516001836020036101000a031916815260200191505b509250505060405180910390fdfe416464726573733a20756e61626c6520746f2073656e642076616c75652c20726563697069656e74206d61792068617665207265766572746564416464726573733a20696e73756666696369656e742062616c616e636520666f722063616c6c526f757465723a206d61726b207072696365206c6f776572207468616e206c696d69745361666545524332303a204552433230206f7065726174696f6e20646964206e6f742073756363656564526f757465723a206d61726b20707269636520686967686572207468616e206c696d6974a2646970667358221220e30349c3ddb101b9febb26097b8103a939c0ee296798912eeff9d7a95081846a64736f6c634300060c00330000000000000000000000001546ec8b238dca09bb39196a18268cbb51a40853000000000000000000000000d5368f3647cd46045fc77ae0b9c46f1c964e3639000000000000000000000000309c92261178fa0cf748a855e90ae73fdb79ebc7
Deployed Bytecode
0x60806040526004361061014f5760003560e01c806390205d8c116100b6578063b7ddc9921161006f578063b7ddc9921461099b578063cedd437514610a71578063cfad57a214610aa4578063d8867fc814610ad7578063f5b91b7b14610b0a578063fbfa77cf14610b1f576101ae565b806390205d8c1461072357806390b64ad314610782578063956f285e146107bb578063a4d95b64146107f6578063abe68eaa14610829578063b32755de146108d8576101ae565b806338c74dd91161010857806338c74dd9146104935780633fc8cef3146104c6578063430ed37c146104db5780634b12e6431461053a5780635fc8500e146105815780636023e96614610661576101ae565b806312d43a51146101b35780631b827878146101e45780631f1dd1761461022d5780632662166b1461027e5780632d4ba6a7146102f15780633039e37f146103b3576101ae565b366101ae576001546001600160a01b031633146101ac576040805162461bcd60e51b81526020600482015260166024820152752937baba32b91d1034b73b30b634b21039b2b73232b960511b604482015290519081900360640190fd5b005b600080fd5b3480156101bf57600080fd5b506101c8610b34565b604080516001600160a01b039092168252519081900360200190f35b3480156101f057600080fd5b506101ac6004803603608081101561020757600080fd5b506001600160a01b03813581169160208101358216916040820135169060600135610b43565b34801561023957600080fd5b506101ac600480360360a081101561025057600080fd5b506001600160a01b038135811691602081013582169160408201351690606081013590608001351515610b67565b34801561028a57600080fd5b506102df600480360360e08110156102a157600080fd5b506001600160a01b0381358116916020810135821691604082013581169160608101359160808201359160a081013515159160c09091013516610bfc565b60408051918252519081900360200190f35b3480156102fd57600080fd5b506101ac6004803603608081101561031457600080fd5b810190602081018135600160201b81111561032e57600080fd5b82018360208201111561034057600080fd5b803590602001918460208302840111600160201b8311171561036157600080fd5b91908080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525092955050823593505050602081013590604001356001600160a01b0316610cbc565b3480156103bf57600080fd5b506101ac60048036036101008110156103d757600080fd5b810190602081018135600160201b8111156103f157600080fd5b82018360208201111561040357600080fd5b803590602001918460208302840111600160201b8311171561042457600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550505081356001600160a01b0390811693506020830135926040810135925060608101351515916080820135169060a08101359060c00135610e3f565b34801561049f57600080fd5b506101ac600480360360208110156104b657600080fd5b50356001600160a01b0316610f4e565b3480156104d257600080fd5b506101c8610f7f565b3480156104e757600080fd5b506101ac600480360360e08110156104fe57600080fd5b506001600160a01b0381358116916020810135821691604082013591606081013591608082013515159160a08101359091169060c00135610f8e565b34801561054657600080fd5b5061056d6004803603602081101561055d57600080fd5b50356001600160a01b0316610fb5565b604080519115158252519081900360200190f35b34801561058d57600080fd5b506101ac60048036036101008110156105a557600080fd5b810190602081018135600160201b8111156105bf57600080fd5b8201836020820111156105d157600080fd5b803590602001918460208302840111600160201b831117156105f257600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550505081356001600160a01b0390811693506020830135926040810135925060608101351515916080820135169060a08101359060c00135610fca565b34801561066d57600080fd5b506101ac6004803603608081101561068457600080fd5b810190602081018135600160201b81111561069e57600080fd5b8201836020820111156106b057600080fd5b803590602001918460208302840111600160201b831117156106d157600080fd5b91908080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525092955050823593505050602081013590604001356001600160a01b0316611010565b34801561072f57600080fd5b506101ac600480360360e081101561074657600080fd5b506001600160a01b0381358116916020810135821691604082013591606081013591608082013515159160a08101359091169060c00135611059565b34801561078e57600080fd5b506101ac600480360360408110156107a557600080fd5b506001600160a01b038135169060200135611068565b3480156107c757600080fd5b5061056d600480360360408110156107de57600080fd5b506001600160a01b03813581169160200135166110f4565b34801561080257600080fd5b506101ac6004803603602081101561081957600080fd5b50356001600160a01b0316611114565b6101ac6004803603606081101561083f57600080fd5b810190602081018135600160201b81111561085957600080fd5b82018360208201111561086b57600080fd5b803590602001918460208302840111600160201b8311171561088c57600080fd5b91908080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525092955050823593505050602001356001600160a01b0316611188565b6101ac600480360360c08110156108ee57600080fd5b810190602081018135600160201b81111561090857600080fd5b82018360208201111561091a57600080fd5b803590602001918460208302840111600160201b8311171561093b57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550506001600160a01b03833516935050506020810135906040810135906060810135151590608001356112b9565b3480156109a757600080fd5b506101ac600480360360e08110156109be57600080fd5b810190602081018135600160201b8111156109d857600080fd5b8201836020820111156109ea57600080fd5b803590602001918460208302840111600160201b83111715610a0b57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550506001600160a01b0383351693505050602081013590604081013590606081013590608081013515159060a001356113b3565b348015610a7d57600080fd5b506101ac60048036036020811015610a9457600080fd5b50356001600160a01b0316611460565b348015610ab057600080fd5b506101ac60048036036020811015610ac757600080fd5b50356001600160a01b031661148e565b348015610ae357600080fd5b506101ac60048036036020811015610afa57600080fd5b50356001600160a01b0316611503565b348015610b1657600080fd5b506101c861157a565b348015610b2b57600080fd5b506101c8611589565b6000546001600160a01b031681565b610b4c83611598565b610b616001600160a01b038516848484611670565b50505050565b610b7085611598565b600354604080516348d91abf60e01b81526001600160a01b03888116600483015287811660248301528681166044830152606482018690528415156084830152915191909216916348d91abf9160a480830192600092919082900301818387803b158015610bdd57600080fd5b505af1158015610bf1573d6000803e3d6000fd5b505050505050505050565b6000610c0788611598565b6003546040805163082a084960e41b81526001600160a01b038b811660048301528a811660248301528981166044830152606482018990526084820188905286151560a483015285811660c4830152915191909216916382a084909160e48083019260209291908290030181600087803b158015610c8457600080fd5b505af1158015610c98573d6000803e3d6000fd5b505050506040513d6020811015610cae57600080fd5b505198975050505050505050565b60015484516001600160a01b039091169085906000198101908110610cdd57fe5b60200260200101516001600160a01b031614610d38576040805162461bcd60e51b81526020600482015260156024820152740a4deeae8cae47440d2dcecc2d8d2c840bee0c2e8d605b1b604482015290519081900360640190fd5b610d82610d436116ca565b60035486516001600160a01b039091169086908890600090610d6157fe5b60200260200101516001600160a01b0316611670909392919063ffffffff16565b6000610d8f8584306116ce565b9050610d9b818361180f565b7fcd3829a3813dc3cdd188fd3d01dcf3268c16be2fdd2dd21d0665418816e460623386600081518110610dca57fe5b602002602001015187600189510381518110610de257fe5b6020026020010151878560405180866001600160a01b03168152602001856001600160a01b03168152602001846001600160a01b031681526020018381526020018281526020019550505050505060405180910390a15050505050565b60015488516001600160a01b039091169089906000198101908110610e6057fe5b60200260200101516001600160a01b031614610ebb576040805162461bcd60e51b81526020600482015260156024820152740a4deeae8cae47440d2dcecc2d8d2c840bee0c2e8d605b1b604482015290519081900360640190fd5b6000610ee089600081518110610ecd57fe5b602002602001015189898989308961188c565b9050610f29600360009054906101000a90046001600160a01b0316828b600081518110610f0957fe5b60200260200101516001600160a01b0316611a999092919063ffffffff16565b6000610f368a84306116ce565b9050610f42818661180f565b50505050505050505050565b3360009081526005602090815260408083206001600160a01b0394909416835292905220805460ff19166001179055565b6001546001600160a01b031681565b6000610f9f8888888888308861188c565b9050610fab818461180f565b5050505050505050565b60046020526000908152604090205460ff1681565b6000610fdc89600081518110610ecd57fe5b9050611005600360009054906101000a90046001600160a01b0316828b600081518110610f0957fe5b610f428983866116ce565b61101b610d436116ca565b60006110288584846116ce565b90507fcd3829a3813dc3cdd188fd3d01dcf3268c16be2fdd2dd21d0665418816e460623386600081518110610dca57fe5b610fab8787878787878761188c565b61108a6110736116ca565b6003546001600160a01b0385811692911684611670565b60035460408051635f7bc11960e01b81526001600160a01b03858116600483015291519190921691635f7bc11991602480830192600092919082900301818387803b1580156110d857600080fd5b505af11580156110ec573d6000803e3d6000fd5b505050505050565b600560209081526000928352604080842090915290825290205460ff1681565b6000546001600160a01b03163314611167576040805162461bcd60e51b81526020600482015260116024820152702937baba32b91d103337b93134b23232b760791b604482015290519081900360640190fd5b6001600160a01b03166000908152600460205260409020805460ff19169055565b60015483516001600160a01b039091169084906000906111a457fe5b60200260200101516001600160a01b0316146111ff576040805162461bcd60e51b81526020600482015260156024820152740a4deeae8cae47440d2dcecc2d8d2c840bee0c2e8d605b1b604482015290519081900360640190fd5b611207611af0565b60006112148484846116ce565b90507fcd3829a3813dc3cdd188fd3d01dcf3268c16be2fdd2dd21d0665418816e46062338560008151811061124557fe5b60200260200101518660018851038151811061125d57fe5b6020026020010151348560405180866001600160a01b03168152602001856001600160a01b03168152602001846001600160a01b031681526020018381526020018281526020019550505050505060405180910390a150505050565b60015486516001600160a01b039091169087906000906112d557fe5b60200260200101516001600160a01b031614611330576040805162461bcd60e51b81526020600482015260156024820152740a4deeae8cae47440d2dcecc2d8d2c840bee0c2e8d605b1b604482015290519081900360640190fd5b341561133e5761133e611af0565b6001865111801561134f5750600034115b1561138f5760006113618786306116ce565b905061138d600360009054906101000a90046001600160a01b0316828960018b510381518110610f0957fe5b505b6110ec866001885103815181106113a257fe5b602002602001015186858585611b79565b84156113e2576113e26113c46116ca565b60035489516001600160a01b039091169088908b90600090610d6157fe5b600187511180156113f35750600085115b156114335760006114058886306116ce565b9050611431600360009054906101000a90046001600160a01b0316828a60018c510381518110610f0957fe5b505b6114578760018951038151811061144657fe5b602002602001015187858585611b79565b50505050505050565b3360009081526005602090815260408083206001600160a01b0394909416835292905220805460ff19169055565b6000546001600160a01b031633146114e1576040805162461bcd60e51b81526020600482015260116024820152702937baba32b91d103337b93134b23232b760791b604482015290519081900360640190fd5b600080546001600160a01b0319166001600160a01b0392909216919091179055565b6000546001600160a01b03163314611556576040805162461bcd60e51b81526020600482015260116024820152702937baba32b91d103337b93134b23232b760791b604482015290519081900360640190fd5b6001600160a01b03166000908152600460205260409020805460ff19166001179055565b6002546001600160a01b031681565b6003546001600160a01b031681565b3360009081526004602052604090205460ff166115f5576040805162461bcd60e51b81526020600482015260166024820152752937baba32b91d1034b73b30b634b21038363ab3b4b760511b604482015290519081900360640190fd5b6001600160a01b038116600090815260056020908152604080832033845290915290205460ff1661166d576040805162461bcd60e51b815260206004820152601b60248201527f526f757465723a20706c7567696e206e6f7420617070726f7665640000000000604482015290519081900360640190fd5b50565b604080516001600160a01b0380861660248301528416604482015260648082018490528251808303909101815260849091019091526020810180516001600160e01b03166323b872dd60e01b179052610b61908590611d74565b3390565b60008351600214156117155761170e846000815181106116ea57fe5b6020026020010151856001815181106116ff57fe5b60200260200101518585611e25565b9050611808565b8351600314156117bb5760006117568560008151811061173157fe5b60200260200101518660018151811061174657fe5b6020026020010151600030611e25565b905061177f600360009054906101000a90046001600160a01b03168287600181518110610f0957fe5b6117b38560018151811061178f57fe5b6020026020010151866002815181106117a457fe5b60200260200101518686611e25565b915050611808565b6040805162461bcd60e51b815260206004820152601c60248201527f526f757465723a20696e76616c6964205f706174682e6c656e67746800000000604482015290519081900360640190fd5b9392505050565b60015460408051632e1a7d4d60e01b81526004810185905290516001600160a01b0390921691632e1a7d4d9160248082019260009290919082900301818387803b15801561185c57600080fd5b505af1158015611870573d6000803e3d6000fd5b50611888925050506001600160a01b03821683612023565b5050565b6000831561195257600354604080516340d3096b60e11b81526001600160a01b038a811660048301529151859392909216916381a612d691602480820192602092909190829003018186803b1580156118e457600080fd5b505afa1580156118f8573d6000803e3d6000fd5b505050506040513d602081101561190e57600080fd5b5051101561194d5760405162461bcd60e51b81526004018080602001828103825260238152602001806123866023913960400191505060405180910390fd5b611a0b565b60035460408051637092736960e11b81526001600160a01b038a8116600483015291518593929092169163e124e6d291602480820192602092909190829003018186803b1580156119a257600080fd5b505afa1580156119b6573d6000803e3d6000fd5b505050506040513d60208110156119cc57600080fd5b50511115611a0b5760405162461bcd60e51b81526004018080602001828103825260248152602001806123d36024913960400191505060405180910390fd5b6003546001600160a01b03166382a08490611a246116ca565b604080516001600160e01b031960e085901b1681526001600160a01b039283166004820152828d166024820152828c166044820152606481018b9052608481018a905288151560a482015291871660c48301525160e48083019260209291908290030181600087803b158015610c8457600080fd5b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b179052611aeb908490611d74565b505050565b600160009054906101000a90046001600160a01b03166001600160a01b031663d0e30db0346040518263ffffffff1660e01b81526004016000604051808303818588803b158015611b4057600080fd5b505af1158015611b54573d6000803e3d6000fd5b5050600354600154611b7794506001600160a01b03908116935016905034611a99565b565b8115611c3d5760035460408051637092736960e11b81526001600160a01b03878116600483015291518493929092169163e124e6d291602480820192602092909190829003018186803b158015611bcf57600080fd5b505afa158015611be3573d6000803e3d6000fd5b505050506040513d6020811015611bf957600080fd5b50511115611c385760405162461bcd60e51b81526004018080602001828103825260248152602001806123d36024913960400191505060405180910390fd5b611cf6565b600354604080516340d3096b60e11b81526001600160a01b0387811660048301529151849392909216916381a612d691602480820192602092909190829003018186803b158015611c8d57600080fd5b505afa158015611ca1573d6000803e3d6000fd5b505050506040513d6020811015611cb757600080fd5b50511015611cf65760405162461bcd60e51b81526004018080602001828103825260238152602001806123866023913960400191505060405180910390fd5b6003546001600160a01b03166348d91abf611d0f6116ca565b604080516001600160e01b031960e085901b1681526001600160a01b039283166004820152828a16602482015291881660448301526064820187905285151560848301525160a480830192600092919082900301818387803b158015610bdd57600080fd5b6060611dc9826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166121089092919063ffffffff16565b805190915015611aeb57808060200190516020811015611de857600080fd5b5051611aeb5760405162461bcd60e51b815260040180806020018281038252602a8152602001806123a9602a913960400191505060405180910390fd5b60025460009081906001600160a01b0386811691161415611eca576003546040805163817bb85760e01b81526001600160a01b03898116600483015286811660248301529151919092169163817bb8579160448083019260209291908290030181600087803b158015611e9757600080fd5b505af1158015611eab573d6000803e3d6000fd5b505050506040513d6020811015611ec157600080fd5b50519050611fc5565b6002546001600160a01b0387811691161415611f375760035460408051630711e61960e41b81526001600160a01b03888116600483015286811660248301529151919092169163711e61909160448083019260209291908290030181600087803b158015611e9757600080fd5b60035460408051634998b10960e11b81526001600160a01b038981166004830152888116602483015286811660448301529151919092169163933162129160648083019260209291908290030181600087803b158015611f9657600080fd5b505af1158015611faa573d6000803e3d6000fd5b505050506040513d6020811015611fc057600080fd5b505190505b8381101561201a576040805162461bcd60e51b815260206004820152601e60248201527f526f757465723a20696e73756666696369656e7420616d6f756e744f75740000604482015290519081900360640190fd5b95945050505050565b80471015612078576040805162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e6365000000604482015290519081900360640190fd5b6040516000906001600160a01b0384169083908381818185875af1925050503d80600081146120c3576040519150601f19603f3d011682016040523d82523d6000602084013e6120c8565b606091505b5050905080611aeb5760405162461bcd60e51b815260040180806020018281038252603a815260200180612326603a913960400191505060405180910390fd5b6060612117848460008561211f565b949350505050565b6060824710156121605760405162461bcd60e51b81526004018080602001828103825260268152602001806123606026913960400191505060405180910390fd5b6121698561227b565b6121ba576040805162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015290519081900360640190fd5b60006060866001600160a01b031685876040518082805190602001908083835b602083106121f95780518252601f1990920191602091820191016121da565b6001836020036101000a03801982511681845116808217855250505050505090500191505060006040518083038185875af1925050503d806000811461225b576040519150601f19603f3d011682016040523d82523d6000602084013e612260565b606091505b5091509150612270828286612281565b979650505050505050565b3b151590565b60608315612290575081611808565b8251156122a05782518084602001fd5b8160405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156122ea5781810151838201526020016122d2565b50505050905090810190601f1680156123175780820380516001836020036101000a031916815260200191505b509250505060405180910390fdfe416464726573733a20756e61626c6520746f2073656e642076616c75652c20726563697069656e74206d61792068617665207265766572746564416464726573733a20696e73756666696369656e742062616c616e636520666f722063616c6c526f757465723a206d61726b207072696365206c6f776572207468616e206c696d69745361666545524332303a204552433230206f7065726174696f6e20646964206e6f742073756363656564526f757465723a206d61726b20707269636520686967686572207468616e206c696d6974a2646970667358221220e30349c3ddb101b9febb26097b8103a939c0ee296798912eeff9d7a95081846a64736f6c634300060c0033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
0000000000000000000000001546ec8b238dca09bb39196a18268cbb51a40853000000000000000000000000d5368f3647cd46045fc77ae0b9c46f1c964e3639000000000000000000000000309c92261178fa0cf748a855e90ae73fdb79ebc7
-----Decoded View---------------
Arg [0] : _vault (address): 0x1546ec8B238dCA09Bb39196a18268CbB51A40853
Arg [1] : _usdg (address): 0xD5368F3647CD46045fc77ae0B9c46f1c964E3639
Arg [2] : _weth (address): 0x309C92261178fA0CF748A855e90Ae73FDb79EBc7
-----Encoded View---------------
3 Constructor Arguments found :
Arg [0] : 0000000000000000000000001546ec8b238dca09bb39196a18268cbb51a40853
Arg [1] : 000000000000000000000000d5368f3647cd46045fc77ae0b9c46f1c964e3639
Arg [2] : 000000000000000000000000309c92261178fa0cf748a855e90ae73fdb79ebc7
Deployed Bytecode Sourcemap
30290:9732:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;31145:4;;-1:-1:-1;;;;;31145:4:0;31131:10;:18;31123:53;;;;;-1:-1:-1;;;31123:53:0;;;;;;;;;;;;-1:-1:-1;;;31123:53:0;;;;;;;;;;;;;;;30290:9732;;;;;30432:18;;;;;;;;;;;;;:::i;:::-;;;;-1:-1:-1;;;;;30432:18:0;;;;;;;;;;;;;;31731:228;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;31731:228:0;;;;;;;;;;;;;;;;;;;;;;:::i;31967:296::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;31967:296:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;32271:395::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;32271:395:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;33591:482;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;33591:482:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;33591:482:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;33591:482:0;;-1:-1:-1;;33591:482:0;;;-1:-1:-1;;;33591:482:0;;;;;;;;-1:-1:-1;;;;;33591:482:0;;:::i;36447:594::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;36447:594:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;36447:594:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;36447:594:0;;-1:-1:-1;;;36447:594:0;;-1:-1:-1;;;;;36447:594:0;;;;-1:-1:-1;36447:594:0;;;;;;;;;;-1:-1:-1;36447:594:0;;;;;;;;;;;;;;;;;;;;;;:::i;31495:111::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;31495:111:0;-1:-1:-1;;;;;31495:111:0;;:::i;30485:19::-;;;;;;;;;;;;;:::i;35611:385::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;35611:385:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;30566:40::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;30566:40:0;-1:-1:-1;;;;;30566:40:0;;:::i;:::-;;;;;;;;;;;;;;;;;;36004:435;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;36004:435:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;36004:435:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;36004:435:0;;-1:-1:-1;;;36004:435:0;;-1:-1:-1;;;;;36004:435:0;;;;-1:-1:-1;36004:435:0;;;;;;;;;;-1:-1:-1;36004:435:0;;;;;;;;;;;;;;;;;;;;;;:::i;32878:342::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;32878:342:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;32878:342:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;32878:342:0;;-1:-1:-1;;32878:342:0;;;-1:-1:-1;;;32878:342:0;;;;;;;;-1:-1:-1;;;;;32878:342:0;;:::i;35301:302::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;35301:302:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;32674:196::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;32674:196:0;;;;;;;;:::i;30613:69::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;30613:69:0;;;;;;;;;;:::i;31388:99::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;31388:99:0;-1:-1:-1;;;;;31388:99:0;;:::i;33228:355::-;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;33228:355:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;33228:355:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;33228:355:0;;-1:-1:-1;;33228:355:0;;;-1:-1:-1;;;33228:355:0;;;-1:-1:-1;;;;;33228:355:0;;:::i;34685:608::-;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;34685:608:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;34685:608:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;34685:608:0;;-1:-1:-1;;;;;;;34685:608:0;;;;-1:-1:-1;;;34685:608:0;;;;;;;;;;;;;;;;;;;;;:::i;34081:596::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;34081:596:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;34081:596:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;34081:596:0;;-1:-1:-1;;;;;;;34081:596:0;;;;-1:-1:-1;;;34081:596:0;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;31614:109::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;31614:109:0;-1:-1:-1;;;;;31614:109:0;;:::i;31192:76::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;31192:76:0;-1:-1:-1;;;;;31192:76:0;;:::i;31276:104::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;31276:104:0;-1:-1:-1;;;;;31276:104:0;;:::i;30511:19::-;;;;;;;;;;;;;:::i;30537:20::-;;;;;;;;;;;;;:::i;30432:18::-;;;-1:-1:-1;;;;;30432:18:0;;:::o;31731:228::-;31854:25;31870:8;31854:15;:25::i;:::-;31890:61;-1:-1:-1;;;;;31890:31:0;;31922:8;31932:9;31943:7;31890:31;:61::i;:::-;31731:228;;;;:::o;31967:296::-;32127:25;32143:8;32127:15;:25::i;:::-;32170:5;;32163:92;;;-1:-1:-1;;;32163:92:0;;-1:-1:-1;;;;;32163:92:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;32170:5;;;;;32163:30;;:92;;;;;32170:5;;32163:92;;;;;;;32170:5;;32163:92;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;31967:296;;;;;:::o;32271:395::-;32474:7;32494:25;32510:8;32494:15;:25::i;:::-;32544:5;;32537:121;;;-1:-1:-1;;;32537:121:0;;-1:-1:-1;;;;;32537:121:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;32544:5;;;;;32537:30;;:121;;;;;;;;;;;;;;32544:5;;32537:121;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;32537:121:0;;32271:395;-1:-1:-1;;;;;;;;32271:395:0:o;33591:482::-;33758:4;;33737:12;;-1:-1:-1;;;;;33758:4:0;;;;33731:5;;-1:-1:-1;;33737:16:0;;;33731:23;;;;;;;;;;;;-1:-1:-1;;;;;33731:31:0;;33723:65;;;;;-1:-1:-1;;;33723:65:0;;;;;;;;;;;;-1:-1:-1;;;33723:65:0;;;;;;;;;;;;;;;33799:62;33833:9;:7;:9::i;:::-;33844:5;;33806:8;;-1:-1:-1;;;;;33844:5:0;;;;33851:9;;33806:5;;33844;;33806:8;;;;;;;;;;-1:-1:-1;;;;;33799:33:0;;;:62;;;;;;:::i;:::-;33872:17;33892:36;33898:5;33905:7;33922:4;33892:5;:36::i;:::-;33872:56;;33939:37;33955:9;33966;33939:15;:37::i;:::-;33992:73;33997:10;34009:5;34015:1;34009:8;;;;;;;;;;;;;;34019:5;34040:1;34025:5;:12;:16;34019:23;;;;;;;;;;;;;;34044:9;34055;33992:73;;;;-1:-1:-1;;;;;33992:73:0;;;;;;-1:-1:-1;;;;;33992:73:0;;;;;;-1:-1:-1;;;;;33992:73:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;33591:482;;;;;:::o;36447:594::-;36703:4;;36682:12;;-1:-1:-1;;;;;36703:4:0;;;;36676:5;;-1:-1:-1;;36682:16:0;;;36676:23;;;;;;;;;;;;-1:-1:-1;;;;;36676:31:0;;36668:65;;;;;-1:-1:-1;;;36668:65:0;;;;;;;;;;;;-1:-1:-1;;;36668:65:0;;;;;;;;;;;;;;;36744:14;36761:102;36779:5;36785:1;36779:8;;;;;;;;;;;;;;36789:11;36802:16;36820:10;36832:7;36849:4;36856:6;36761:17;:102::i;:::-;36744:119;;36874:44;36904:5;;;;;;;;;-1:-1:-1;;;;;36904:5:0;36911:6;36881:5;36887:1;36881:8;;;;;;;;;;;;;;-1:-1:-1;;;;;36874:29:0;;;:44;;;;;:::i;:::-;36929:17;36949:36;36955:5;36962:7;36979:4;36949:5;:36::i;:::-;36929:56;;36996:37;37012:9;37023;36996:15;:37::i;:::-;36447:594;;;;;;;;;;:::o;31495:111::-;31571:10;31555:27;;;;:15;:27;;;;;;;;-1:-1:-1;;;;;31555:36:0;;;;;;;;;;:43;;-1:-1:-1;;31555:43:0;31594:4;31555:43;;;31495:111::o;30485:19::-;;;-1:-1:-1;;;;;30485:19:0;;:::o;35611:385::-;35810:17;35830:110;35848:16;35866:11;35879:16;35897:10;35909:7;35926:4;35933:6;35830:17;:110::i;:::-;35810:130;;35951:37;35967:9;35978;35951:15;:37::i;:::-;35611:385;;;;;;;;:::o;30566:40::-;;;;;;;;;;;;;;;:::o;36004:435::-;36214:14;36231:102;36249:5;36255:1;36249:8;;;;;;;36231:102;36214:119;;36344:44;36374:5;;;;;;;;;-1:-1:-1;;;;;36374:5:0;36381:6;36351:5;36357:1;36351:8;;;;;;;36344:44;36399:32;36405:5;36412:7;36421:9;36399:5;:32::i;32878:342::-;32998:62;33032:9;:7;:9::i;32998:62::-;33071:17;33091:32;33097:5;33104:7;33113:9;33091:5;:32::i;:::-;33071:52;;33139:73;33144:10;33156:5;33162:1;33156:8;;;;;;;35301:302;35489:106;35507:16;35525:11;35538:16;35556:10;35568:7;35577:9;35588:6;35489:17;:106::i;32674:196::-;32754:58;32786:9;:7;:9::i;:::-;32797:5;;-1:-1:-1;;;;;32754:31:0;;;;:58;32797:5;32804:7;32754:31;:58::i;:::-;32830:5;;32823:39;;;-1:-1:-1;;;32823:39:0;;-1:-1:-1;;;;;32823:39:0;;;;;;;;;32830:5;;;;;32823:31;;:39;;;;;32830:5;;32823:39;;;;;;;32830:5;;32823:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;32674:196;;:::o;30613:69::-;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;31388:99::-;30851:3;;-1:-1:-1;;;;;30851:3:0;30837:10;:17;30829:47;;;;;-1:-1:-1;;;30829:47:0;;;;;;;;;;;;-1:-1:-1;;;30829:47:0;;;;;;;;;;;;;;;-1:-1:-1;;;;;31455:16:0::1;31474:5;31455:16:::0;;;:7:::1;:16;::::0;;;;:24;;-1:-1:-1;;31455:24:0::1;::::0;;31388:99::o;33228:355::-;33361:4;;33349:8;;-1:-1:-1;;;;;33361:4:0;;;;33349:5;;33361:4;;33349:8;;;;;;;;;;-1:-1:-1;;;;;33349:16:0;;33341:50;;;;;-1:-1:-1;;;33341:50:0;;;;;;;;;;;;-1:-1:-1;;;33341:50:0;;;;;;;;;;;;;;;33402:21;:19;:21::i;:::-;33434:17;33454:32;33460:5;33467:7;33476:9;33454:5;:32::i;:::-;33434:52;;33502:73;33507:10;33519:5;33525:1;33519:8;;;;;;;;;;;;;;33529:5;33550:1;33535:5;:12;:16;33529:23;;;;;;;;;;;;;;33554:9;33565;33502:73;;;;-1:-1:-1;;;;;33502:73:0;;;;;;-1:-1:-1;;;;;33502:73:0;;;;;;-1:-1:-1;;;;;33502:73:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;33228:355;;;;:::o;34685:608::-;34874:4;;34862:8;;-1:-1:-1;;;;;34874:4:0;;;;34862:5;;34874:4;;34862:8;;;;;;;;;;-1:-1:-1;;;;;34862:16:0;;34854:50;;;;;-1:-1:-1;;;34854:50:0;;;;;;;;;;;;-1:-1:-1;;;34854:50:0;;;;;;;;;;;;;;;34919:9;:13;34915:67;;34949:21;:19;:21::i;:::-;35011:1;34996:5;:12;:16;:33;;;;;35028:1;35016:9;:13;34996:33;34992:199;;;35046:17;35066:36;35072:5;35079:7;35096:4;35066:5;:36::i;:::-;35046:56;;35117:62;35162:5;;;;;;;;;-1:-1:-1;;;;;35162:5:0;35169:9;35124:5;35145:1;35130:5;:12;:16;35124:23;;;;;;;35117:62;34992:199;;35201:84;35219:5;35240:1;35225:5;:12;:16;35219:23;;;;;;;;;;;;;;35244:11;35257:10;35269:7;35278:6;35201:17;:84::i;34081:596::-;34262:13;;34258:108;;34292:62;34326:9;:7;:9::i;:::-;34337:5;;34299:8;;-1:-1:-1;;;;;34337:5:0;;;;34344:9;;34299:5;;34337;;34299:8;;;34292:62;34395:1;34380:5;:12;:16;:33;;;;;34412:1;34400:9;:13;34380:33;34376:199;;;34430:17;34450:36;34456:5;34463:7;34480:4;34450:5;:36::i;:::-;34430:56;;34501:62;34546:5;;;;;;;;;-1:-1:-1;;;;;34546:5:0;34553:9;34508:5;34529:1;34514:5;:12;:16;34508:23;;;;;;;34501:62;34376:199;;34585:84;34603:5;34624:1;34609:5;:12;:16;34603:23;;;;;;;;;;;;;;34628:11;34641:10;34653:7;34662:6;34585:17;:84::i;:::-;34081:596;;;;;;;:::o;31614:109::-;31687:10;31710:5;31671:27;;;:15;:27;;;;;;;;-1:-1:-1;;;;;31671:36:0;;;;;;;;;;:44;;-1:-1:-1;;31671:44:0;;;31614:109::o;31192:76::-;30851:3;;-1:-1:-1;;;;;30851:3:0;30837:10;:17;30829:47;;;;;-1:-1:-1;;;30829:47:0;;;;;;;;;;;;-1:-1:-1;;;30829:47:0;;;;;;;;;;;;;;;31250:3:::1;:10:::0;;-1:-1:-1;;;;;;31250:10:0::1;-1:-1:-1::0;;;;;31250:10:0;;;::::1;::::0;;;::::1;::::0;;31192:76::o;31276:104::-;30851:3;;-1:-1:-1;;;;;30851:3:0;30837:10;:17;30829:47;;;;;-1:-1:-1;;;30829:47:0;;;;;;;;;;;;-1:-1:-1;;;30829:47:0;;;;;;;;;;;;;;;-1:-1:-1;;;;;31349:16:0::1;;::::0;;;:7:::1;:16;::::0;;;;:23;;-1:-1:-1;;31349:23:0::1;31368:4;31349:23;::::0;;31276:104::o;30511:19::-;;;-1:-1:-1;;;;;30511:19:0;;:::o;30537:20::-;;;-1:-1:-1;;;;;30537:20:0;;:::o;39802:217::-;39885:10;39877:19;;;;:7;:19;;;;;;;;39869:54;;;;;-1:-1:-1;;;39869:54:0;;;;;;;;;;;;-1:-1:-1;;;39869:54:0;;;;;;;;;;;;;;;-1:-1:-1;;;;;39942:25:0;;;;;;:15;:25;;;;;;;;39968:10;39942:37;;;;;;;;;;39934:77;;;;;-1:-1:-1;;;39934:77:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;39802:217;:::o;17103:205::-;17231:68;;;-1:-1:-1;;;;;17231:68:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;17231:68:0;-1:-1:-1;;;17231:68:0;;;17204:96;;17224:5;;17204:19;:96::i;39708:86::-;39776:10;39708:86;:::o;38548:533::-;38640:7;38664:5;:12;38680:1;38664:17;38660:107;;;38705:50;38716:5;38722:1;38716:8;;;;;;;;;;;;;;38726:5;38732:1;38726:8;;;;;;;;;;;;;;38736:7;38745:9;38705:10;:50::i;:::-;38698:57;;;;38660:107;38781:5;:12;38797:1;38781:17;38777:246;;;38815:14;38832:48;38843:5;38849:1;38843:8;;;;;;;;;;;;;;38853:5;38859:1;38853:8;;;;;;;;;;;;;;38863:1;38874:4;38832:10;:48::i;:::-;38815:65;;38895:44;38925:5;;;;;;;;;-1:-1:-1;;;;;38925:5:0;38932:6;38902:5;38908:1;38902:8;;;;;;;38895:44;38961:50;38972:5;38978:1;38972:8;;;;;;;;;;;;;;38982:5;38988:1;38982:8;;;;;;;;;;;;;;38992:7;39001:9;38961:10;:50::i;:::-;38954:57;;;;;38777:246;39035:38;;;-1:-1:-1;;;39035:38:0;;;;;;;;;;;;;;;;;;;;;;;;;;;38548:533;;;;;;:::o;38367:173::-;38464:4;;38458:32;;;-1:-1:-1;;;38458:32:0;;;;;;;;;;-1:-1:-1;;;;;38464:4:0;;;;38458:20;;:32;;;;;38464:4;;38458:32;;;;;;;;38464:4;;38458:32;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;38501:31:0;;-1:-1:-1;;;;;;;;38501:19:0;;38521:10;38501:19;:31::i;:::-;38367:173;;:::o;37579:621::-;37765:7;37789;37785:266;;;37828:5;;37821:38;;;-1:-1:-1;;;37821:38:0;;-1:-1:-1;;;;;37821:38:0;;;;;;;;;37863:6;;37828:5;;;;;37821:25;;:38;;;;;;;;;;;;;;;37828:5;37821:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;37821:38:0;:48;;37813:96;;;;-1:-1:-1;;;37813:96:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;37785:266;;;37957:5;;37950:38;;;-1:-1:-1;;;37950:38:0;;-1:-1:-1;;;;;37950:38:0;;;;;;;;;37992:6;;37957:5;;;;;37950:25;;:38;;;;;;;;;;;;;;;37957:5;37950:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;37950:38:0;:48;;37942:97;;;;-1:-1:-1;;;37942:97:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;38077:5;;-1:-1:-1;;;;;38077:5:0;38070:30;38101:9;:7;:9::i;:::-;38070:122;;;-1:-1:-1;;;;;;38070:122:0;;;;;;;-1:-1:-1;;;;;38070:122:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;38070:122:0;;;;;;;;;;;16918:177;17028:58;;;-1:-1:-1;;;;;17028:58:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;17028:58:0;-1:-1:-1;;;17028:58:0;;;17001:86;;17021:5;;17001:19;:86::i;:::-;16918:177;;;:::o;38208:151::-;38264:4;;;;;;;;;-1:-1:-1;;;;;38264:4:0;-1:-1:-1;;;;;38258:19:0;;38285:9;38258:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;38334:5:0;;;38315:4;38308:43;;-1:-1:-1;;;;;;38315:4:0;;;;-1:-1:-1;38334:5:0;;-1:-1:-1;38341:9:0;38308:25;:43::i;:::-;38208:151::o;37049:522::-;37196:7;37192:266;;;37235:5;;37228:38;;;-1:-1:-1;;;37228:38:0;;-1:-1:-1;;;;;37228:38:0;;;;;;;;;37270:6;;37235:5;;;;;37228:25;;:38;;;;;;;;;;;;;;;37235:5;37228:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;37228:38:0;:48;;37220:97;;;;-1:-1:-1;;;37220:97:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;37192:266;;;37365:5;;37358:38;;;-1:-1:-1;;;37358:38:0;;-1:-1:-1;;;;;37358:38:0;;;;;;;;;37400:6;;37365:5;;;;;37358:25;;:38;;;;;;;;;;;;;;;37365:5;37358:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;37358:38:0;:48;;37350:96;;;;-1:-1:-1;;;37350:96:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;37477:5;;-1:-1:-1;;;;;37477:5:0;37470:30;37501:9;:7;:9::i;:::-;37470:93;;;-1:-1:-1;;;;;;37470:93:0;;;;;;;-1:-1:-1;;;;;37470:93:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;37470:93:0;;;;;;;-1:-1:-1;37470:93:0;;;;;;;;;;;19223:761;19647:23;19673:69;19701:4;19673:69;;;;;;;;;;;;;;;;;19681:5;-1:-1:-1;;;;;19673:27:0;;;:69;;;;;:::i;:::-;19757:17;;19647:95;;-1:-1:-1;19757:21:0;19753:224;;19899:10;19888:30;;;;;;;;;;;;;;;-1:-1:-1;19888:30:0;19880:85;;;;-1:-1:-1;;;19880:85:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;39089:611;39266:4;;39199:7;;;;-1:-1:-1;;;;;39253:17:0;;;39266:4;;39253:17;39249:341;;;39317:5;;39310:42;;;-1:-1:-1;;;39310:42:0;;-1:-1:-1;;;;;39310:42:0;;;;;;;;;;;;;;;;39317:5;;;;;39310:21;;:42;;;;;;;;;;;;;;39317:5;;39310:42;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;39310:42:0;;-1:-1:-1;39249:341:0;;;39386:4;;-1:-1:-1;;;;;39374:16:0;;;39386:4;;39374:16;39370:220;;;39438:5;;39431:44;;;-1:-1:-1;;;39431:44:0;;-1:-1:-1;;;;;39431:44:0;;;;;;;;;;;;;;;;39438:5;;;;;39431:22;;:44;;;;;;;;;;;;;;39438:5;;39431:44;;;;;;;;;;39370:220;39535:5;;39528:50;;;-1:-1:-1;;;39528:50:0;;-1:-1:-1;;;;;39528:50:0;;;;;;;;;;;;;;;;;;;;;;;39535:5;;;;;39528:18;;:50;;;;;;;;;;;;;;39535:5;;39528:50;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;39528:50:0;;-1:-1:-1;39370:220:0;39623:7;39610:9;:20;;39602:63;;;;;-1:-1:-1;;;39602:63:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;39683:9;39089:611;-1:-1:-1;;;;;39089:611:0:o;4985:397::-;5100:6;5075:21;:31;;5067:73;;;;;-1:-1:-1;;;5067:73:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;5250:35;;5232:12;;-1:-1:-1;;;;;5250:14:0;;;5273:6;;5232:12;5250:35;5232:12;5250:35;5273:6;5250:14;:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5231:54;;;5304:7;5296:78;;;;-1:-1:-1;;;5296:78:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6546:195;6649:12;6681:52;6703:6;6711:4;6717:1;6720:12;6681:21;:52::i;:::-;6674:59;6546:195;-1:-1:-1;;;;6546:195:0:o;7598:530::-;7725:12;7783:5;7758:21;:30;;7750:81;;;;-1:-1:-1;;;7750:81:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7850:18;7861:6;7850:10;:18::i;:::-;7842:60;;;;;-1:-1:-1;;;7842:60:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;7976:12;7990:23;8017:6;-1:-1:-1;;;;;8017:11:0;8037:5;8045:4;8017:33;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;8017:33:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7975:75;;;;8068:52;8086:7;8095:10;8107:12;8068:17;:52::i;:::-;8061:59;7598:530;-1:-1:-1;;;;;;;7598:530:0:o;3628:422::-;3995:20;4034:8;;;3628:422::o;10138:742::-;10253:12;10282:7;10278:595;;;-1:-1:-1;10313:10:0;10306:17;;10278:595;10427:17;;:21;10423:439;;10690:10;10684:17;10751:15;10738:10;10734:2;10730:19;10723:44;10638:148;10833:12;10826:20;;-1:-1:-1;;;10826:20:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Swarm Source
ipfs://e30349c3ddb101b9febb26097b8103a939c0ee296798912eeff9d7a95081846a
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.