false
false
5713000

Contract Address Details

0x9E4df6f08ceEcfEF170FCbF036B97789d5320ec3

Token
Fox Genesis Collection (FGC)
Creator
0x218e9e–98c862 at 0x01ca5e–c2135d
Balance
0 PUNDIAI
Tokens
Fetching tokens...
Transactions
235 Transactions
Transfers
0 Transfers
Gas Used
18,093,490
Last Balance Update
22450652
Warning! Contract bytecode has been changed and doesn't match the verified one. Therefore, interaction with this smart contract may be risky.
Contract name:
FoxGenesisCollection




Optimization enabled
true
Compiler version
v0.8.4+commit.c7e474f2




Optimization runs
200
EVM Version
default




Verified at
2022-12-29T21:07:44.823736Z

Constructor Arguments

000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000016466f782047656e6573697320436f6c6c656374696f6e00000000000000000000000000000000000000000000000000000000000000000000000000000000000346474300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007697066733a2f2f00000000000000000000000000000000000000000000000000

Arg [0] (string) : Fox Genesis Collection
Arg [1] (string) : FGC
Arg [2] (string) : ipfs://

              

Contract source code

// Sources flattened with hardhat v2.9.2 https://hardhat.org
// SPDX-License-Identifier: MIT
pragma solidity 0.8.4;


// File contracts/dependencies/Strings.sol

/**
 * @dev String operations.
 */
library Strings {
    bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef";

    /**
     * @dev Converts a `uint256` to its ASCII `string` decimal representation.
     */
    function toString(uint256 value) internal pure returns (string memory) {
        // Inspired by OraclizeAPI's implementation - MIT licence
        // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol

        if (value == 0) {
            return "0";
        }
        uint256 temp = value;
        uint256 digits;
        while (temp != 0) {
            digits++;
            temp /= 10;
        }
        bytes memory buffer = new bytes(digits);
        while (value != 0) {
            digits -= 1;
            buffer[digits] = bytes1(uint8(48 + uint256(value % 10)));
            value /= 10;
        }
        return string(buffer);
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
     */
    function toHexString(uint256 value) internal pure returns (string memory) {
        if (value == 0) {
            return "0x00";
        }
        uint256 temp = value;
        uint256 length = 0;
        while (temp != 0) {
            length++;
            temp >>= 8;
        }
        return toHexString(value, length);
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.
     */
    function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {
        bytes memory buffer = new bytes(2 * length + 2);
        buffer[0] = "0";
        buffer[1] = "x";
        for (uint256 i = 2 * length + 1; i > 1; --i) {
            buffer[i] = _HEX_SYMBOLS[value & 0xf];
            value >>= 4;
        }
        require(value == 0, "Strings: hex length insufficient");
        return string(buffer);
    }
}


// File contracts/dependencies/SafeMath.sol

/**
 * @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/dependencies/Context.sol

/**
 * @dev Provides information about the current execution context, including the
 * sender of the transaction and its data. While these are generally available
 * via msg.sender and msg.data, they should not be accessed in such a direct
 * manner, since when dealing with meta-transactions the account sending and
 * paying for execution may not be the actual sender (as far as an application
 * is concerned).
 *
 * This contract is only required for intermediate, library-like contracts.
 */
abstract contract Context {
    function _msgSender() internal view virtual returns (address) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes calldata) {
        return msg.data;
    }
}

// File contracts/dependencies/Ownable.sol

/**
 * @dev Contract module which provides a basic access control mechanism, where
 * there is an account (an owner) that can be granted exclusive access to
 * specific functions.
 *
 * By default, the owner account will be the one that deploys the contract. This
 * can later be changed with {transferOwnership}.
 *
 * This module is used through inheritance. It will make available the modifier
 * `onlyOwner`, which can be applied to your functions to restrict their use to
 * the owner.
 */
abstract contract Ownable is Context {
    address private _owner;

    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor() {
        _setOwner(_msgSender());
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view virtual returns (address) {
        return _owner;
    }

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        require(owner() == _msgSender(), "Ownable: caller is not the owner");
        _;
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions anymore. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby removing any functionality that is only available to the owner.
     */
    function renounceOwnership() public virtual onlyOwner {
        _setOwner(address(0));
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Can only be called by the current owner.
     */
    function transferOwnership(address newOwner) public virtual onlyOwner {
        require(newOwner != address(0), "Ownable: new owner is the zero address");
        _setOwner(newOwner);
    }

    function _setOwner(address newOwner) private {
        address oldOwner = _owner;
        _owner = newOwner;
        emit OwnershipTransferred(oldOwner, newOwner);
    }
}

// File contracts/dependencies/Address.sol

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
   * @dev Returns whether the target address is a contract.
   * @param _addr Address to check.
   * @return addressCheck True if _addr is a contract, false if not.
   */
  function isContract(address _addr) internal view returns (bool addressCheck)
  {
    // This method relies in extcodesize, which returns 0 for contracts in
    // construction, since the code is only stored at the end of the
    // constructor execution.

    // According to EIP-1052, 0x0 is the value returned for not-yet created accounts
    // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470 is returned
    // for accounts without code, i.e. `keccak256('')`
    bytes32 codehash;
    bytes32 accountHash = 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470;
    assembly { codehash := extcodehash(_addr) } // solhint-disable-line
    addressCheck = (codehash != 0x0 && codehash != accountHash);
  }

    /**
     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to
     * `recipient`, forwarding all available gas and reverting on errors.
     *
     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
     * of certain opcodes, possibly making contracts go over the 2300 gas limit
     * imposed by `transfer`, making them unable to receive funds via
     * `transfer`. {sendValue} removes this limitation.
     *
     * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
     *
     * IMPORTANT: because control is transferred to `recipient`, care must be
     * taken to not create reentrancy vulnerabilities. Consider using
     * {ReentrancyGuard} or the
     * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
     */
    function sendValue(address payable recipient, uint256 amount) internal {
        require(address(this).balance >= amount, "Address: insufficient balance");

        (bool success, ) = recipient.call{value: amount}("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }

    /**
     * @dev Performs a Solidity function call using a low level `call`. A
     * plain `call` is an unsafe replacement for a function call: use this
     * function instead.
     *
     * If `target` reverts with a revert reason, it is bubbled up by this
     * function (like regular Solidity function calls).
     *
     * Returns the raw returned data. To convert to the expected return value,
     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
     *
     * Requirements:
     *
     * - `target` must be a contract.
     * - calling `target` with `data` must not revert.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionCall(target, data, "Address: low-level call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
     * `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, 0, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but also transferring `value` wei to `target`.
     *
     * Requirements:
     *
     * - the calling contract must have an ETH balance of at least `value`.
     * - the called Solidity function must be `payable`.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
    }

    /**
     * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
     * with `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(address(this).balance >= value, "Address: insufficient balance for call");
        require(isContract(target), "Address: call to non-contract");

        (bool success, bytes memory returndata) = target.call{value: value}(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

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

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

        (bool success, bytes memory returndata) = target.staticcall(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

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

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

        (bool success, bytes memory returndata) = target.delegatecall(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the
     * revert reason using the provided one.
     *
     * _Available since v4.3._
     */
    function verifyCallResult(
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal pure returns (bytes memory) {
        if (success) {
            return returndata;
        } else {
            // Look for revert reason and bubble it up if present
            if (returndata.length > 0) {
                // The easiest way to bubble the revert reason is using memory via assembly

                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}


// File contracts/dependencies/IERC165.sol

/**
 * @dev Interface of the ERC165 standard, as defined in the
 * https://eips.ethereum.org/EIPS/eip-165[EIP].
 *
 * Implementers can declare support of contract interfaces, which can then be
 * queried by others ({ERC165Checker}).
 *
 * For an implementation, see {ERC165}.
 */
interface IERC165 {
    /**
     * @dev Returns true if this contract implements the interface defined by
     * `interfaceId`. See the corresponding
     * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
     * to learn more about how these ids are created.
     *
     * This function call must use less than 30 000 gas.
     */
    function supportsInterface(bytes4 interfaceId) external view returns (bool);
    /*
     function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        return interfaceId == type(IERC165).interfaceId;
    }
    */
}


// File contracts/dependencies/ERC165.sol

/**
 * @dev Implementation of the {IERC165} interface.
 *
 * Contracts may inherit from this and call {_registerInterface} to declare
 * their support of an interface.
 */
contract ERC165 is IERC165 {
    /*
     * bytes4(keccak256('supportsInterface(bytes4)')) == 0x01ffc9a7
     */
    bytes4 private constant _INTERFACE_ID_ERC165 = 0x01ffc9a7;

    /**
     * @dev Mapping of interface ids to whether or not it's supported.
     */
    mapping(bytes4 => bool) private _supportedInterfaces;

    constructor ()  {
        // Derived contracts need only register support for their own interfaces,
        // we register support for ERC165 itself here
        _registerInterface(_INTERFACE_ID_ERC165);
    }

    /**
     * @dev See {IERC165-supportsInterface}.
     *
     * Time complexity O(1), guaranteed to always use less than 30 000 gas.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        return _supportedInterfaces[interfaceId];
    }

    /**
     * @dev Registers the contract as an implementer of the interface defined by
     * `interfaceId`. Support of the actual ERC165 interface is automatic and
     * registering its interface id is not required.
     *
     * See {IERC165-supportsInterface}.
     *
     * Requirements:
     *
     * - `interfaceId` cannot be the ERC165 invalid interface (`0xffffffff`).
     */
    function _registerInterface(bytes4 interfaceId) internal virtual {
        require(interfaceId != 0xffffffff, "ERC165: invalid interface id");
        _supportedInterfaces[interfaceId] = true;
    }
}


// File contracts/dependencies/IERC721.sol

/**
 * @dev Required interface of an ERC721 compliant contract.
 */
interface IERC721 is IERC165 {
    /**
     * @dev Emitted when `tokenId` token is transferred from `from` to `to`.
     */
    event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);

    /**
     * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token.
     */
    event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);

    /**
     * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets.
     */
    event ApprovalForAll(address indexed owner, address indexed operator, bool approved);

    /**
     * @dev Returns the number of tokens in ``owner``'s account.
     */
    function balanceOf(address owner) external view returns (uint256 balance);

    /**
     * @dev Returns the owner of the `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function ownerOf(uint256 tokenId) external view returns (address owner);

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
     * are aware of the ERC721 protocol to prevent tokens from being forever locked.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

    /**
     * @dev Transfers `tokenId` token from `from` to `to`.
     *
     * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;
    /**
     * @dev Gives permission to `to` to transfer `tokenId` token to another account.
     * The approval is cleared when the token is transferred.
     *
     * Only a single account can be approved at a time, so approving the zero address clears previous approvals.
     *
     * Requirements:
     *
     * - The caller must own the token or be an approved operator.
     * - `tokenId` must exist.
     *
     * Emits an {Approval} event.
     */
    function approve(address to, uint256 tokenId) external;

    /**
     * @dev Returns the account approved for `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function getApproved(uint256 tokenId) external view returns (address operator);

    /**
     * @dev Approve or remove `operator` as an operator for the caller.
     * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller.
     *
     * Requirements:
     *
     * - The `operator` cannot be the caller.
     *
     * Emits an {ApprovalForAll} event.
     */
    function setApprovalForAll(address operator, bool _approved) external;

    /**
     * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`.
     *
     * See {setApprovalForAll}
     */
    function isApprovedForAll(address owner, address operator) external view returns (bool);

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes calldata data
    ) external;
}


// File contracts/dependencies/IERC20.sol

// OpenZeppelin Contracts (last updated v4.5.0) (token/ERC20/IERC20.sol)

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

    /**
     * @dev Emitted when the allowance of a `spender` for an `owner` is set by
     * a call to {approve}. `value` is the new allowance.
     */
    event Approval(address indexed owner, address indexed spender, uint256 value);

    /**
     * @dev 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 `to`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address to, 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 `from` to `to` 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 from,
        address to,
        uint256 amount
    ) external returns (bool);
}

// File contracts/dependencies/IERC721Metadata.sol

/**
 * @title ERC-721 Non-Fungible Token Standard, optional metadata extension
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
interface IERC721Metadata is IERC721 {
    /**
     * @dev Returns the token collection name.
     */
    function name() external view returns (string memory);

    /**
     * @dev Returns the token collection symbol.
     */
    function symbol() external view returns (string memory);

    /**
     * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token.
     */
    function tokenURI(uint256 tokenId) external view returns (string memory);
}


// File contracts/dependencies/IERC721Receiver.sol

/**
 * @title ERC721 token receiver interface
 * @dev Interface for any contract that wants to support safeTransfers
 * from ERC721 asset contracts.
 */
interface IERC721Receiver {
    /**
     * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}
     * by `operator` from `from`, this function is called.
     *
     * It must return its Solidity selector to confirm the token transfer.
     * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted.
     *
     * The selector can be obtained in Solidity with `IERC721.onERC721Received.selector`.
     */
    function onERC721Received(
        address operator,
        address from,
        uint256 tokenId,
        bytes calldata data
    ) external returns (bytes4);
}

// File contracts/dependencies/ERC721A.sol

error ApprovalCallerNotOwnerNorApproved();
error ApprovalQueryForNonexistentToken();
error ApproveToCaller();
error ApprovalToCurrentOwner();
error BalanceQueryForZeroAddress();
error MintToZeroAddress();
error MintZeroQuantity();
error OwnerQueryForNonexistentToken();
error TransferCallerNotOwnerNorApproved();
error TransferFromIncorrectOwner();
error TransferToNonERC721ReceiverImplementer();
error TransferToZeroAddress();
error URIQueryForNonexistentToken();

/**
 * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including
 * the Metadata extension. Built to optimize for lower gas during batch mints.
 *
 * Assumes serials are sequentially minted starting at _startTokenId() (defaults to 0, e.g. 0, 1, 2, 3..).
 *
 * Assumes that an owner cannot have more than 2**64 - 1 (max value of uint64) of supply.
 *
 * Assumes that the maximum token id cannot exceed 2**256 - 1 (max value of uint256).
 */
contract ERC721A is Context, ERC165, IERC721, IERC721Metadata {
    using Address for address;
    using Strings for uint256;
    mapping (address => bool) public whitelists;

    // Compiler will pack this into a single 256bit word.
    struct TokenOwnership {
        // The address of the owner.
        address addr;
        // Keeps track of the start time of ownership with minimal overhead for tokenomics.
        uint64 startTimestamp;
        // Whether the token has been burned.
        bool burned;
    }

    // Compiler will pack this into a single 256bit word.
    struct AddressData {
        // Realistically, 2**64-1 is more than enough.
        uint64 balance;
        // Keeps track of mint count with minimal overhead for tokenomics.
        uint64 numberMinted;
        // Keeps track of burn count with minimal overhead for tokenomics.
        uint64 numberBurned;
        // For miscellaneous variable(s) pertaining to the address
        // (e.g. number of whitelist mint slots used).
        // If there are multiple variables, please pack them into a uint64.
        uint64 aux;
    }

    // The tokenId of the next token to be minted.
    uint256 internal _currentIndex;

    // The number of tokens burned.
    uint256 internal _burnCounter;

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

    // Base URI
    string private _baseURI;
    /**
     * @dev Internal function to set the base URI for all token IDs. It is
     * automatically added as a prefix to the value returned in {tokenURI},
     * or to the token ID if {tokenURI} is empty.
     */
    function _setBaseURI(string memory baseURI_) internal virtual {
        _baseURI = baseURI_;
    }
    /**
    * @dev Returns the base URI set via {_setBaseURI}. This will be
    * automatically added as a prefix in {tokenURI} to each token's URI, or
    * to the token ID if no specific URI is set for that token ID.
    */
    function baseURI() public view returns (string memory) {
        return _baseURI;
    }
    // Mapping from token ID to ownership details
    // An empty struct value does not necessarily mean the token is unowned. See _ownershipOf implementation for details.
    mapping(uint256 => TokenOwnership) internal _ownerships;

    // Mapping owner address to address data
    mapping(address => AddressData) private _addressData;

    // Mapping from token ID to approved address
    mapping(uint256 => address) private _tokenApprovals;

    // Mapping from owner to operator approvals
    mapping(address => mapping(address => bool)) private _operatorApprovals;

    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
        _currentIndex = _startTokenId();
    }

    /**
     * To change the starting tokenId, please override this function.
     */
    function _startTokenId() internal view virtual returns (uint256) {
        return 1;
    }

    /**
     * @dev Burned tokens are calculated here, use _totalMinted() if you want to count just minted tokens.
     */
    function totalSupply() public view returns (uint256) {
        // Counter underflow is impossible as _burnCounter cannot be incremented
        // more than _currentIndex - _startTokenId() times
        unchecked {
            return _currentIndex - _burnCounter - _startTokenId();
        }
    }

    /**
     * Returns the total amount of tokens minted in the contract.
     */
    function _totalMinted() internal view returns (uint256) {
        // Counter underflow is impossible as _currentIndex does not decrement,
        // and it is initialized to _startTokenId()
        unchecked {
            return _currentIndex - _startTokenId();
        }
    }

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) {
        return
            interfaceId == type(IERC721).interfaceId ||
            interfaceId == type(IERC721Metadata).interfaceId ||
            super.supportsInterface(interfaceId);
    }

    /**
     * @dev See {IERC721-balanceOf}.
     */
    function balanceOf(address owner) public view override returns (uint256) {
        if (owner == address(0)) revert BalanceQueryForZeroAddress();
        return uint256(_addressData[owner].balance);
    }

    /**
     * Returns the number of tokens minted by `owner`.
     */
    function _numberMinted(address owner) internal view returns (uint256) {
        return uint256(_addressData[owner].numberMinted);
    }

    /**
     * Returns the number of tokens burned by or on behalf of `owner`.
     */
    function _numberBurned(address owner) internal view returns (uint256) {
        return uint256(_addressData[owner].numberBurned);
    }

    /**
     * Returns the auxillary data for `owner`. (e.g. number of whitelist mint slots used).
     */
    function _getAux(address owner) internal view returns (uint64) {
        return _addressData[owner].aux;
    }

    /**
     * Sets the auxillary data for `owner`. (e.g. number of whitelist mint slots used).
     * If there are multiple variables, please pack them into a uint64.
     */
    function _setAux(address owner, uint64 aux) internal {
        _addressData[owner].aux = aux;
    }

    /**
     * Gas spent here starts off proportional to the maximum mint batch size.
     * It gradually moves to O(1) as tokens get transferred around in the collection over time.
     */
    function _ownershipOf(uint256 tokenId) internal view returns (TokenOwnership memory) {
        uint256 curr = tokenId;

        unchecked {
            if (_startTokenId() <= curr && curr < _currentIndex) {
                TokenOwnership memory ownership = _ownerships[curr];
                if (!ownership.burned) {
                    if (ownership.addr != address(0)) {
                        return ownership;
                    }
                    // Invariant:
                    // There will always be an ownership that has an address and is not burned
                    // before an ownership that does not have an address and is not burned.
                    // Hence, curr will not underflow.
                    while (true) {
                        curr--;
                        ownership = _ownerships[curr];
                        if (ownership.addr != address(0)) {
                            return ownership;
                        }
                    }
                }
            }
        }
        revert OwnerQueryForNonexistentToken();
    }

    /**
     * @dev See {IERC721-ownerOf}.
     */
    function ownerOf(uint256 tokenId) public view override returns (address) {
        return _ownershipOf(tokenId).addr;
    }

    /**
     * @dev See {IERC721Metadata-name}.
     */
    function name() public view virtual override returns (string memory) {
        return _name;
    }

    /**
     * @dev See {IERC721Metadata-symbol}.
     */
    function symbol() public view virtual override returns (string memory) {
        return _symbol;
    }

    /**
     * @dev See {IERC721Metadata-tokenURI}.
     */
    function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
        if (!_exists(tokenId)) revert URIQueryForNonexistentToken();

        string memory base_URI = baseURI();

        return bytes(base_URI).length != 0 ? string(abi.encodePacked(base_URI, tokenId.toString(), ".json")) : '';
    }


    /**
     * @dev See {IERC721-approve}.
     */
    function approve(address to, uint256 tokenId) public override {
        address owner = ERC721A.ownerOf(tokenId);
        if (to == owner) revert ApprovalToCurrentOwner();

        if (_msgSender() != owner && !isApprovedForAll(owner, _msgSender())) {
            revert ApprovalCallerNotOwnerNorApproved();
        }

        _approve(to, tokenId, owner);
    }

    /**
     * @dev See {IERC721-getApproved}.
     */
    function getApproved(uint256 tokenId) public view override returns (address) {
        if (!_exists(tokenId)) revert ApprovalQueryForNonexistentToken();

        return _tokenApprovals[tokenId];
    }

    /**
     * @dev See {IERC721-setApprovalForAll}.
     */
    function setApprovalForAll(address operator, bool approved) public virtual override {
        if (operator == _msgSender()) revert ApproveToCaller();

        _operatorApprovals[_msgSender()][operator] = approved;
        emit ApprovalForAll(_msgSender(), operator, approved);
    }

    /**
     * @dev See {IERC721-isApprovedForAll}.
     */
    function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) {
        return _operatorApprovals[owner][operator];
    }

    /**
     * @dev See {IERC721-transferFrom}.
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public virtual override {
        _transfer(from, to, tokenId);
    }

    /**
     * @dev See {IERC721-safeTransferFrom}.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public virtual override {
        safeTransferFrom(from, to, tokenId, '');
    }

    /**
     * @dev See {IERC721-safeTransferFrom}.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) public virtual override {
        _transfer(from, to, tokenId);
        if (to.isContract() && !_checkContractOnERC721Received(from, to, tokenId, _data)) {
            revert TransferToNonERC721ReceiverImplementer();
        }
    }

    /**
     * @dev Returns whether `tokenId` exists.
     *
     * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}.
     *
     * Tokens start existing when they are minted (`_mint`),
     */
    function _exists(uint256 tokenId) internal view returns (bool) {
        return _startTokenId() <= tokenId && tokenId < _currentIndex &&
            !_ownerships[tokenId].burned;
    }

    function _safeMint(address to, uint256 quantity) internal {
        _safeMint(to, quantity, '');
    }

    /**
     * @dev Safely mints `quantity` tokens and transfers them to `to`.
     *
     * Requirements:
     *
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called for each safe transfer.
     * - `quantity` must be greater than 0.
     *
     * Emits a {Transfer} event.
     */
    function _safeMint(
        address to,
        uint256 quantity,
        bytes memory _data
    ) internal {
        _mint(to, quantity, _data, true);
    }

    /**
     * @dev Mints `quantity` tokens and transfers them to `to`.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `quantity` must be greater than 0.
     *
     * Emits a {Transfer} event.
     */
    function _mint(
        address to,
        uint256 quantity,
        bytes memory _data,
        bool safe
    ) internal {
        uint256 startTokenId = _currentIndex;
        if (to == address(0)) revert MintToZeroAddress();
        if (quantity == 0) revert MintZeroQuantity();

        _beforeTokenTransfers(address(0), to, startTokenId, quantity);

        // Overflows are incredibly unrealistic.
        // balance or numberMinted overflow if current value of either + quantity > 1.8e19 (2**64) - 1
        // updatedIndex overflows if _currentIndex + quantity > 1.2e77 (2**256) - 1
        unchecked {
            _addressData[to].balance += uint64(quantity);
            _addressData[to].numberMinted += uint64(quantity);

            _ownerships[startTokenId].addr = to;
            _ownerships[startTokenId].startTimestamp = uint64(block.timestamp);

            uint256 updatedIndex = startTokenId;
            uint256 end = updatedIndex + quantity;

            if (safe && to.isContract()) {
                do {
                    emit Transfer(address(0), to, updatedIndex);
                    if (!_checkContractOnERC721Received(address(0), to, updatedIndex++, _data)) {
                        revert TransferToNonERC721ReceiverImplementer();
                    }
                } while (updatedIndex != end);
                // Reentrancy protection
                if (_currentIndex != startTokenId) revert();
            } else {
                do {
                    emit Transfer(address(0), to, updatedIndex++);
                } while (updatedIndex != end);
            }
            _currentIndex = updatedIndex;
        }
        _afterTokenTransfers(address(0), to, startTokenId, quantity);
    }

    /**
     * @dev Transfers `tokenId` from `from` to `to`.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     *
     * Emits a {Transfer} event.
     */
    function _transfer(
        address from,
        address to,
        uint256 tokenId
    ) private {
        TokenOwnership memory prevOwnership = _ownershipOf(tokenId);

        if (prevOwnership.addr != from) revert TransferFromIncorrectOwner();

        bool isApprovedOrOwner = (_msgSender() == from ||
            isApprovedForAll(from, _msgSender()) ||
            getApproved(tokenId) == _msgSender());

        if (!isApprovedOrOwner) revert TransferCallerNotOwnerNorApproved();
        if (to == address(0)) revert TransferToZeroAddress();

        _beforeTokenTransfers(from, to, tokenId, 1);

        // Clear approvals from the previous owner
        _approve(address(0), tokenId, from);

        // Underflow of the sender's balance is impossible because we check for
        // ownership above and the recipient's balance can't realistically overflow.
        // Counter overflow is incredibly unrealistic as tokenId would have to be 2**256.
        unchecked {
            _addressData[from].balance -= 1;
            _addressData[to].balance += 1;

            TokenOwnership storage currSlot = _ownerships[tokenId];
            currSlot.addr = to;
            currSlot.startTimestamp = uint64(block.timestamp);

            // If the ownership slot of tokenId+1 is not explicitly set, that means the transfer initiator owns it.
            // Set the slot of tokenId+1 explicitly in storage to maintain correctness for ownerOf(tokenId+1) calls.
            uint256 nextTokenId = tokenId + 1;
            TokenOwnership storage nextSlot = _ownerships[nextTokenId];
            if (nextSlot.addr == address(0)) {
                // This will suffice for checking _exists(nextTokenId),
                // as a burned slot cannot contain the zero address.
                if (nextTokenId != _currentIndex) {
                    nextSlot.addr = from;
                    nextSlot.startTimestamp = prevOwnership.startTimestamp;
                }
            }
        }

        emit Transfer(from, to, tokenId);
        _afterTokenTransfers(from, to, tokenId, 1);
    }

    /**
     * @dev This is equivalent to _burn(tokenId, false)
     */
    function _burn(uint256 tokenId) internal virtual {
        _burn(tokenId, false);
    }

    /**
     * @dev Destroys `tokenId`.
     * The approval is cleared when the token is burned.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     *
     * Emits a {Transfer} event.
     */
    function _burn(uint256 tokenId, bool approvalCheck) internal virtual {
        TokenOwnership memory prevOwnership = _ownershipOf(tokenId);

        address from = prevOwnership.addr;

        if (approvalCheck) {
            bool isApprovedOrOwner = (_msgSender() == from ||
                isApprovedForAll(from, _msgSender()) ||
                getApproved(tokenId) == _msgSender());

            if (!isApprovedOrOwner) revert TransferCallerNotOwnerNorApproved();
        }

        _beforeTokenTransfers(from, address(0), tokenId, 1);

        // Clear approvals from the previous owner
        _approve(address(0), tokenId, from);

        // Underflow of the sender's balance is impossible because we check for
        // ownership above and the recipient's balance can't realistically overflow.
        // Counter overflow is incredibly unrealistic as tokenId would have to be 2**256.
        unchecked {
            AddressData storage addressData = _addressData[from];
            addressData.balance -= 1;
            addressData.numberBurned += 1;

            // Keep track of who burned the token, and the timestamp of burning.
            TokenOwnership storage currSlot = _ownerships[tokenId];
            currSlot.addr = from;
            currSlot.startTimestamp = uint64(block.timestamp);
            currSlot.burned = true;

            // If the ownership slot of tokenId+1 is not explicitly set, that means the burn initiator owns it.
            // Set the slot of tokenId+1 explicitly in storage to maintain correctness for ownerOf(tokenId+1) calls.
            uint256 nextTokenId = tokenId + 1;
            TokenOwnership storage nextSlot = _ownerships[nextTokenId];
            if (nextSlot.addr == address(0)) {
                // This will suffice for checking _exists(nextTokenId),
                // as a burned slot cannot contain the zero address.
                if (nextTokenId != _currentIndex) {
                    nextSlot.addr = from;
                    nextSlot.startTimestamp = prevOwnership.startTimestamp;
                }
            }
        }

        emit Transfer(from, address(0), tokenId);
        _afterTokenTransfers(from, address(0), tokenId, 1);

        // Overflow not possible, as _burnCounter cannot be exceed _currentIndex times.
        unchecked {
            _burnCounter++;
        }
    }

    /**
     * @dev Approve `to` to operate on `tokenId`
     *
     * Emits a {Approval} event.
     */
    function _approve(
        address to,
        uint256 tokenId,
        address owner
    ) private {
        _tokenApprovals[tokenId] = to;
        emit Approval(owner, to, tokenId);
    }

    /**
     * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target contract.
     *
     * @param from address representing the previous owner of the given token ID
     * @param to target address that will receive the tokens
     * @param tokenId uint256 ID of the token to be transferred
     * @param _data bytes optional data to send along with the call
     * @return bool whether the call correctly returned the expected magic value
     */
    function _checkContractOnERC721Received(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) private returns (bool) {
        try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) {
            return retval == IERC721Receiver(to).onERC721Received.selector;
        } catch (bytes memory reason) {
            if (reason.length == 0) {
                revert TransferToNonERC721ReceiverImplementer();
            } else {
                assembly {
                    revert(add(32, reason), mload(reason))
                }
            }
        }
    }

    /**
     * @dev Hook that is called before a set of serially-ordered token ids are about to be transferred. This includes minting.
     * And also called before burning one token.
     *
     * startTokenId - the first token id to be transferred
     * quantity - the amount to be transferred
     *
     * Calling conditions:
     *
     * - When `from` and `to` are both non-zero, `from`'s `tokenId` will be
     * transferred to `to`.
     * - When `from` is zero, `tokenId` will be minted for `to`.
     * - When `to` is zero, `tokenId` will be burned by `from`.
     * - `from` and `to` are never both zero.
     */
    function _beforeTokenTransfers(
        address from,
        address to,
        uint256 startTokenId,
        uint256 quantity
    ) internal virtual {}

    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {}

    /**
     * @dev Hook that is called after a set of serially-ordered token ids have been transferred. This includes
     * minting.
     * And also called after one token has been burned.
     *
     * startTokenId - the first token id to be transferred
     * quantity - the amount to be transferred
     *
     * Calling conditions:
     *
     * - When `from` and `to` are both non-zero, `from`'s `tokenId` has been
     * transferred to `to`.
     * - When `from` is zero, `tokenId` has been minted for `to`.
     * - When `to` is zero, `tokenId` has been burned by `from`.
     * - `from` and `to` are never both zero.
     */
    function _afterTokenTransfers(
        address from,
        address to,
        uint256 startTokenId,
        uint256 quantity
    ) internal virtual {}
}


// File contracts/dependencies/Pausable.sol

/**
 * @dev Contract module which allows children to implement an emergency stop
 * mechanism that can be triggered by an authorized account.
 *
 * This module is used through inheritance. It will make available the
 * modifiers `whenNotPaused` and `whenPaused`, which can be applied to
 * the functions of your contract. Note that they will not be pausable by
 * simply including this module, only once the modifiers are put in place.
 */
abstract contract Pausable is Context {
    /**
     * @dev Emitted when the pause is triggered by `account`.
     */
    event Paused(address account);

    /**
     * @dev Emitted when the pause is lifted by `account`.
     */
    event Unpaused(address account);

    bool private _paused;

    /**
     * @dev Initializes the contract in unpaused state.
     */
    constructor() {
        _paused = false;
    }

    /**
     * @dev Returns true if the contract is paused, and false otherwise.
     */
    function paused() public view virtual returns (bool) {
        return _paused;
    }

    /**
     * @dev Modifier to make a function callable only when the contract is not paused.
     *
     * Requirements:
     *
     * - The contract must not be paused.
     */
    modifier whenNotPaused() {
        require(!paused(), "Pausable: paused");
        _;
    }

    /**
     * @dev Modifier to make a function callable only when the contract is paused.
     *
     * Requirements:
     *
     * - The contract must be paused.
     */
    modifier whenPaused() {
        require(paused(), "Pausable: not paused");
        _;
    }

    /**
     * @dev Triggers stopped state.
     *
     * Requirements:
     *
     * - The contract must not be paused.
     */
    function _pause() internal virtual whenNotPaused {
        _paused = true;
        emit Paused(_msgSender());
    }

    /**
     * @dev Returns to normal state.
     *
     * Requirements:
     *
     * - The contract must be paused.
     */
    function _unpause() internal virtual whenPaused {
        _paused = false;
        emit Unpaused(_msgSender());
    }
}


// File contracts/dependencies/ERC721Pausable.sol

/**
 * @dev ERC721 token with pausable token transfers, minting and burning.
 *
 * Useful for scenarios such as preventing trades until the end of an evaluation
 * period, or having an emergency switch for freezing all token transfers in the
 * event of a large bug.
 */
abstract contract ERC721APausable is ERC721A, Pausable {
    /**
     * @dev See {ERC721-_beforeTokenTransfer}.
     *
     * Requirements:
     *
     * - the contract must not be paused.
     */
    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual override {
        super._beforeTokenTransfer(from, to, tokenId);

        require(!paused(), "ERC721Pausable: token transfer while paused");
    }
}



contract FoxGenesisCollection is Ownable, ERC721A, ERC721APausable {

    using SafeMath for uint256;
    using Address for address;

    uint256 public totalSales;
    uint256 public numberOfWhitelisted;

    uint public maxToMint = 2500;
    uint public mintFee = 267*1e18;
    uint public maxPerTransaction = 100;
    uint256 public maxPerWallet = 100;
    uint256 public maxFree = 100;
    mapping (address => uint256 ) public minted;

    // =========== Start Smart Contract Setup ==============
    address payable public fundsWallet = payable(0x7126579EC75a22D25F29ED2E54eB4886B6976d17);
    address payable public admin = payable(0x218e9eE150231C242EC5120FCE00DfFE8498C862);
    bool public whitelistingEnabled = false;
    bool public mintingEnabled = false;
    bool public freezeMetadata = false;

    /**
     *
     * Token URIs will be autogenerated based on `baseURI` and their token IDs.
     * See {ERC721-tokenURI}.
     */
    constructor(string memory name, string memory symbol, string memory _baseURI)  ERC721A(name, symbol) {
        transferOwnership(fundsWallet);
        _setBaseURI(_baseURI);
    }

    function setMaxPerWallet(uint256 _maxPerWallet) public virtual {
        require( owner() == _msgSender() || admin == _msgSender(), "NonFungibleToken: must have DEFAULT_ADMIN_ROLE");
        maxPerWallet = _maxPerWallet;
    }

    function setFreezeMetadata() public virtual {
        require( owner() == _msgSender() || admin == _msgSender(), "NonFungibleToken: must have DEFAULT_ADMIN_ROLE");
        require(! freezeMetadata, "NonFungibleToken: already frozen !");

        freezeMetadata = true;
    }

    function setURI(string memory _baseURI) public virtual {
        require( owner() == _msgSender() || admin == _msgSender(), "NonFungibleToken: must have admin role");
        require(! freezeMetadata, "Metadata frozen !");
        _setBaseURI(_baseURI);
    }

    function setOwner(address _owner) public virtual {
        require( owner() == _msgSender() , "NonFungibleToken: must have admin role");
        transferOwnership(_owner);
    }
    function setFundsWallet(address _wallet) public virtual {
        require( owner() == _msgSender(), "NonFungibleToken: must have admin role");
        fundsWallet = payable(_wallet);
    }
    function toggleMinting(bool _bool) public virtual {
        require( owner() == _msgSender() || admin == _msgSender(), "NonFungibleToken: must have admin role to mint");
        mintingEnabled = _bool;

    }

    function whitelist(address[] memory _beneficiaries) external {
      require( owner() == _msgSender() || admin == _msgSender(), "NonFungibleToken: must have admin role");
      for (uint256 i = 0; i < _beneficiaries.length; i++) {
        if (! whitelists[_beneficiaries[i]]){
            numberOfWhitelisted = numberOfWhitelisted + 1;
        }
        whitelists[_beneficiaries[i]] = true;
      }
    }

    function removeFromWhitelist(address[] memory _beneficiaries) external {
      require( owner() == _msgSender() || admin == _msgSender(), "NonFungibleToken: must have admin role");
      for (uint256 i = 0; i < _beneficiaries.length; i++) {

        if (whitelists[_beneficiaries[i]]){
            numberOfWhitelisted = numberOfWhitelisted.sub(1);
        }
        whitelists[_beneficiaries[i]] = false;
      }
    }

    function contractURI() public view returns (string memory) {
        return string(abi.encodePacked(baseURI(), "contract-metadata.json"));
    }

    function setAdmin(address _admin) public  {
        require (_msgSender() == admin || _msgSender() == owner(), "Only admin or owner");
        admin = payable(_admin);
    }

    function setMintFee(uint _mintFee) public {
        require (_msgSender() == admin || _msgSender() == owner(), "Only admin or owner");
        mintFee = _mintFee;
    }

    function setMaxFreeFee(uint _max) public {
        require (_msgSender() == admin || _msgSender() == owner(), "Only admin or owner");
        maxFree = _max;
    }

    function setMaxPerTransaction(uint _max) public  {
        require (_msgSender() == admin || _msgSender() == owner(), "Only admin or owner");

        maxPerTransaction = _max;
    }

    function toggleWhitelisting(bool _toggle) public virtual {
        require (_msgSender() == admin || _msgSender() == owner(), "Only admin or owner");
        whitelistingEnabled = _toggle;
    }

    event ERC721Received(address operator, address from, uint256 tokenId, bytes data);

    function onERC721Received(address operator, address from, uint256 tokenId, bytes memory data) public returns(bytes4) {
        emit ERC721Received(operator, from, tokenId, data);
        return this.onERC721Received.selector;
    }

    function airdrop(address[] memory _beneficiaries) external {
      require( owner() == _msgSender() || admin == _msgSender(),  "ERROR: must have admin role");
      require(mintingEnabled, "Minting not enabled !");
      for (uint256 i = 0; i < _beneficiaries.length; i++) {
        _safeMint(_beneficiaries[i], 1);
      }
    }

    function mintOperation(address to, uint256 count) internal {
        require(mintingEnabled, "Minting not enabled !");
        require(whitelists[to] || ! whitelistingEnabled, "User not whitelisted !");
        require (count <= maxPerTransaction, "maxPerTransaction reached");
        uint256 totalMinted = totalSupply();
        require (totalMinted.add(count) <= maxToMint, "Max supply reached");
        require(minted[msg.sender].add(count) <= maxPerWallet, "Max NFTs reached by wallet");

        if (totalMinted.add(count) > maxFree){
            require(msg.value >= mintFee.mul(count), "Insufficient fees");
   
            (bool success, ) = fundsWallet.call{ value: msg.value }("");

            require(success, "Address: unable to send value, recipient may have reverted");
        }

        totalSales = totalSales.add(msg.value);

        _safeMint(to, count);
        minted[msg.sender] = minted[msg.sender].add(count);

    }

    function mint(uint256 count) payable public {
        mintOperation(_msgSender(), count);
    }

    function _beforeTokenTransfer(address from, address to, uint256 tokenId) internal virtual override(ERC721A, ERC721APausable) {
        super._beforeTokenTransfer(from, to, tokenId);
    }
}
        

Contract ABI

[{"type":"constructor","stateMutability":"nonpayable","inputs":[{"type":"string","name":"name","internalType":"string"},{"type":"string","name":"symbol","internalType":"string"},{"type":"string","name":"_baseURI","internalType":"string"}]},{"type":"error","name":"ApprovalCallerNotOwnerNorApproved","inputs":[]},{"type":"error","name":"ApprovalQueryForNonexistentToken","inputs":[]},{"type":"error","name":"ApprovalToCurrentOwner","inputs":[]},{"type":"error","name":"ApproveToCaller","inputs":[]},{"type":"error","name":"BalanceQueryForZeroAddress","inputs":[]},{"type":"error","name":"MintToZeroAddress","inputs":[]},{"type":"error","name":"MintZeroQuantity","inputs":[]},{"type":"error","name":"OwnerQueryForNonexistentToken","inputs":[]},{"type":"error","name":"TransferCallerNotOwnerNorApproved","inputs":[]},{"type":"error","name":"TransferFromIncorrectOwner","inputs":[]},{"type":"error","name":"TransferToNonERC721ReceiverImplementer","inputs":[]},{"type":"error","name":"TransferToZeroAddress","inputs":[]},{"type":"error","name":"URIQueryForNonexistentToken","inputs":[]},{"type":"event","name":"Approval","inputs":[{"type":"address","name":"owner","internalType":"address","indexed":true},{"type":"address","name":"approved","internalType":"address","indexed":true},{"type":"uint256","name":"tokenId","internalType":"uint256","indexed":true}],"anonymous":false},{"type":"event","name":"ApprovalForAll","inputs":[{"type":"address","name":"owner","internalType":"address","indexed":true},{"type":"address","name":"operator","internalType":"address","indexed":true},{"type":"bool","name":"approved","internalType":"bool","indexed":false}],"anonymous":false},{"type":"event","name":"ERC721Received","inputs":[{"type":"address","name":"operator","internalType":"address","indexed":false},{"type":"address","name":"from","internalType":"address","indexed":false},{"type":"uint256","name":"tokenId","internalType":"uint256","indexed":false},{"type":"bytes","name":"data","internalType":"bytes","indexed":false}],"anonymous":false},{"type":"event","name":"OwnershipTransferred","inputs":[{"type":"address","name":"previousOwner","internalType":"address","indexed":true},{"type":"address","name":"newOwner","internalType":"address","indexed":true}],"anonymous":false},{"type":"event","name":"Paused","inputs":[{"type":"address","name":"account","internalType":"address","indexed":false}],"anonymous":false},{"type":"event","name":"Transfer","inputs":[{"type":"address","name":"from","internalType":"address","indexed":true},{"type":"address","name":"to","internalType":"address","indexed":true},{"type":"uint256","name":"tokenId","internalType":"uint256","indexed":true}],"anonymous":false},{"type":"event","name":"Unpaused","inputs":[{"type":"address","name":"account","internalType":"address","indexed":false}],"anonymous":false},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address payable"}],"name":"admin","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"airdrop","inputs":[{"type":"address[]","name":"_beneficiaries","internalType":"address[]"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"approve","inputs":[{"type":"address","name":"to","internalType":"address"},{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"balanceOf","inputs":[{"type":"address","name":"owner","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"baseURI","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"contractURI","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"freezeMetadata","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address payable"}],"name":"fundsWallet","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"getApproved","inputs":[{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"isApprovedForAll","inputs":[{"type":"address","name":"owner","internalType":"address"},{"type":"address","name":"operator","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"maxFree","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"maxPerTransaction","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"maxPerWallet","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"maxToMint","inputs":[]},{"type":"function","stateMutability":"payable","outputs":[],"name":"mint","inputs":[{"type":"uint256","name":"count","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"mintFee","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"minted","inputs":[{"type":"address","name":"","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"mintingEnabled","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"name","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"numberOfWhitelisted","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bytes4","name":"","internalType":"bytes4"}],"name":"onERC721Received","inputs":[{"type":"address","name":"operator","internalType":"address"},{"type":"address","name":"from","internalType":"address"},{"type":"uint256","name":"tokenId","internalType":"uint256"},{"type":"bytes","name":"data","internalType":"bytes"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"owner","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"ownerOf","inputs":[{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"paused","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"removeFromWhitelist","inputs":[{"type":"address[]","name":"_beneficiaries","internalType":"address[]"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"renounceOwnership","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"safeTransferFrom","inputs":[{"type":"address","name":"from","internalType":"address"},{"type":"address","name":"to","internalType":"address"},{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"safeTransferFrom","inputs":[{"type":"address","name":"from","internalType":"address"},{"type":"address","name":"to","internalType":"address"},{"type":"uint256","name":"tokenId","internalType":"uint256"},{"type":"bytes","name":"_data","internalType":"bytes"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setAdmin","inputs":[{"type":"address","name":"_admin","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setApprovalForAll","inputs":[{"type":"address","name":"operator","internalType":"address"},{"type":"bool","name":"approved","internalType":"bool"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setFreezeMetadata","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setFundsWallet","inputs":[{"type":"address","name":"_wallet","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setMaxFreeFee","inputs":[{"type":"uint256","name":"_max","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setMaxPerTransaction","inputs":[{"type":"uint256","name":"_max","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setMaxPerWallet","inputs":[{"type":"uint256","name":"_maxPerWallet","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setMintFee","inputs":[{"type":"uint256","name":"_mintFee","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setOwner","inputs":[{"type":"address","name":"_owner","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setURI","inputs":[{"type":"string","name":"_baseURI","internalType":"string"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"supportsInterface","inputs":[{"type":"bytes4","name":"interfaceId","internalType":"bytes4"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"symbol","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"toggleMinting","inputs":[{"type":"bool","name":"_bool","internalType":"bool"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"toggleWhitelisting","inputs":[{"type":"bool","name":"_toggle","internalType":"bool"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"tokenURI","inputs":[{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"totalSales","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"totalSupply","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"transferFrom","inputs":[{"type":"address","name":"from","internalType":"address"},{"type":"address","name":"to","internalType":"address"},{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"transferOwnership","inputs":[{"type":"address","name":"newOwner","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"whitelist","inputs":[{"type":"address[]","name":"_beneficiaries","internalType":"address[]"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"whitelistingEnabled","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"whitelists","inputs":[{"type":"address","name":"","internalType":"address"}]}]
              

Contract Creation Code

0x60806040526109c4600f55680e795e8d5f954c0000601055606460118190556012819055601355601580546001600160a01b031916737126579ec75a22d25f29ed2e54eb4886b6976d17179055601680546001600160b81b03191673218e9ee150231c242ec5120fce00dffe8498c8621790553480156200007f57600080fd5b5060405162002fdb38038062002fdb833981016040819052620000a29162000444565b8282620000af3362000129565b620000c16301ffc9a760e01b62000179565b8151620000d6906005906020850190620002eb565b508051620000ec906006906020840190620002eb565b5060016003555050600c805460ff1916905560155462000115906001600160a01b031662000201565b6200012081620002d2565b50505062000524565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6001600160e01b03198082161415620001d95760405162461bcd60e51b815260206004820152601c60248201527f4552433136353a20696e76616c696420696e746572666163652069640000000060448201526064015b60405180910390fd5b6001600160e01b0319166000908152600160208190526040909120805460ff19169091179055565b6000546001600160a01b031633146200025d5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401620001d0565b6001600160a01b038116620002c45760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401620001d0565b620002cf8162000129565b50565b8051620002e7906007906020840190620002eb565b5050565b828054620002f990620004d1565b90600052602060002090601f0160209004810192826200031d576000855562000368565b82601f106200033857805160ff191683800117855562000368565b8280016001018555821562000368579182015b82811115620003685782518255916020019190600101906200034b565b50620003769291506200037a565b5090565b5b808211156200037657600081556001016200037b565b600082601f830112620003a2578081fd5b81516001600160401b0380821115620003bf57620003bf6200050e565b604051601f8301601f19908116603f01168101908282118183101715620003ea57620003ea6200050e565b8160405283815260209250868385880101111562000406578485fd5b8491505b838210156200042957858201830151818301840152908201906200040a565b838211156200043a57848385830101525b9695505050505050565b60008060006060848603121562000459578283fd5b83516001600160401b038082111562000470578485fd5b6200047e8783880162000391565b9450602086015191508082111562000494578384fd5b620004a28783880162000391565b93506040860151915080821115620004b8578283fd5b50620004c78682870162000391565b9150509250925092565b600181811c90821680620004e657607f821691505b602082108114156200050857634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052604160045260246000fd5b612aa780620005346000396000f3fe6080604052600436106102c95760003560e01c80636352211e11610175578063a22cb465116100dc578063d111515d11610095578063e985e9c51161006f578063e985e9c51461086f578063eddd0d9c1461088f578063f2fde38b146108af578063f851a440146108cf57600080fd5b8063d111515d14610819578063e268e4d31461083a578063e8a3d4851461085a57600080fd5b8063a22cb46514610763578063a92ba3c714610783578063b88d4fde14610799578063bd8aa780146107b9578063c87b56dd146107d9578063ccfdd2f8146107f957600080fd5b8063715018a61161012e578063715018a6146106c7578063729ad39e146106dc5780638da5cb5b146106fc57806395d89b411461071a5780639fd6db121461072f578063a0712d681461075057600080fd5b80636352211e1461061c57806364e39b871461063c5780636605ff661461065c5780636c0360eb14610672578063704b6c021461068757806370a08231146106a757600080fd5b806321775c92116102345780634b980d67116101ed57806355adffd1116101c757806355adffd1146105a35780635b0c29eb146105c35780635c975abb146105e45780636082adf8146105fc57600080fd5b80634b980d6714610558578063539d5c871461056e578063548db1741461058357600080fd5b806321775c92146104ac5780632194f3a2146104cc57806323b872dd146104ec57806342842e0e1461050c578063453c23101461052c578063485a68a31461054257600080fd5b806313966db51161028657806313966db5146103c357806313af4035146103d9578063150b7a02146103f957806318160ddd146104325780631e7269c51461044f5780631e7be2101461047c57600080fd5b806301ffc9a7146102ce57806302fe53051461030357806306fdde0314610325578063081812fc14610347578063095ea7b31461037f5780630ba133c51461039f575b600080fd5b3480156102da57600080fd5b506102ee6102e93660046126a4565b6108ef565b60405190151581526020015b60405180910390f35b34801561030f57600080fd5b5061032361031e3660046126dc565b61094a565b005b34801561033157600080fd5b5061033a6109ec565b6040516102fa919061281c565b34801561035357600080fd5b50610367610362366004612722565b610a7e565b6040516001600160a01b0390911681526020016102fa565b34801561038b57600080fd5b5061032361039a3660046125b2565b610ac2565b3480156103ab57600080fd5b506103b5600f5481565b6040519081526020016102fa565b3480156103cf57600080fd5b506103b560105481565b3480156103e557600080fd5b506103236103f4366004612489565b610b50565b34801561040557600080fd5b50610419610414366004612510565b610b83565b6040516001600160e01b031990911681526020016102fa565b34801561043e57600080fd5b5060045460035403600019016103b5565b34801561045b57600080fd5b506103b561046a366004612489565b60146020526000908152604090205481565b34801561048857600080fd5b506102ee610497366004612489565b60026020526000908152604090205460ff1681565b3480156104b857600080fd5b506103236104c736600461268a565b610bd4565b3480156104d857600080fd5b50601554610367906001600160a01b031681565b3480156104f857600080fd5b506103236105073660046124d5565b610c78565b34801561051857600080fd5b506103236105273660046124d5565b610c83565b34801561053857600080fd5b506103b560125481565b34801561054e57600080fd5b506103b560135481565b34801561056457600080fd5b506103b560115481565b34801561057a57600080fd5b50610323610c9e565b34801561058f57600080fd5b5061032361059e3660046125db565b610d57565b3480156105af57600080fd5b506103236105be366004612722565b610e72565b3480156105cf57600080fd5b506016546102ee90600160a01b900460ff1681565b3480156105f057600080fd5b50600c5460ff166102ee565b34801561060857600080fd5b5061032361061736600461268a565b610ebf565b34801561062857600080fd5b50610367610637366004612722565b610f25565b34801561064857600080fd5b50610323610657366004612489565b610f37565b34801561066857600080fd5b506103b5600d5481565b34801561067e57600080fd5b5061033a610f83565b34801561069357600080fd5b506103236106a2366004612489565b610f92565b3480156106b357600080fd5b506103b56106c2366004612489565b610ffc565b3480156106d357600080fd5b5061032361104b565b3480156106e857600080fd5b506103236106f73660046125db565b6110b1565b34801561070857600080fd5b506000546001600160a01b0316610367565b34801561072657600080fd5b5061033a6111c1565b34801561073b57600080fd5b506016546102ee90600160a81b900460ff1681565b61032361075e366004612722565b6111d0565b34801561076f57600080fd5b5061032361077e366004612589565b6111da565b34801561078f57600080fd5b506103b5600e5481565b3480156107a557600080fd5b506103236107b4366004612510565b611270565b3480156107c557600080fd5b506103236107d43660046125db565b6112c6565b3480156107e557600080fd5b5061033a6107f4366004612722565b6113dc565b34801561080557600080fd5b50610323610814366004612722565b611461565b34801561082557600080fd5b506016546102ee90600160b01b900460ff1681565b34801561084657600080fd5b50610323610855366004612722565b6114ae565b34801561086657600080fd5b5061033a6114f2565b34801561087b57600080fd5b506102ee61088a3660046124a3565b611520565b34801561089b57600080fd5b506103236108aa366004612722565b61154e565b3480156108bb57600080fd5b506103236108ca366004612489565b61159b565b3480156108db57600080fd5b50601654610367906001600160a01b031681565b60006001600160e01b031982166380ac58cd60e01b148061092057506001600160e01b03198216635b5e139f60e01b145b8061094457506001600160e01b0319821660009081526001602052604090205460ff165b92915050565b6000546001600160a01b031633148061096d57506016546001600160a01b031633145b6109925760405162461bcd60e51b8152600401610989906128aa565b60405180910390fd5b601654600160b01b900460ff16156109e05760405162461bcd60e51b81526020600482015260116024820152704d657461646174612066726f7a656e202160781b6044820152606401610989565b6109e981611663565b50565b6060600580546109fb906129af565b80601f0160208091040260200160405190810160405280929190818152602001828054610a27906129af565b8015610a745780601f10610a4957610100808354040283529160200191610a74565b820191906000526020600020905b815481529060010190602001808311610a5757829003601f168201915b5050505050905090565b6000610a8982611676565b610aa6576040516333d1c03960e21b815260040160405180910390fd5b506000908152600a60205260409020546001600160a01b031690565b6000610acd82610f25565b9050806001600160a01b0316836001600160a01b03161415610b025760405163250fdee360e21b815260040160405180910390fd5b336001600160a01b03821614801590610b225750610b208133611520565b155b15610b40576040516367d9dca160e11b815260040160405180910390fd5b610b4b8383836116af565b505050565b6000546001600160a01b03163314610b7a5760405162461bcd60e51b8152600401610989906128aa565b6109e98161159b565b60007fa05d90f300156ad1b545bc5d8197024456f21d22a708f5af04dd293e3d60525185858585604051610bba94939291906127df565b60405180910390a150630a85bd0160e11b5b949350505050565b6000546001600160a01b0316331480610bf757506016546001600160a01b031633145b610c5a5760405162461bcd60e51b815260206004820152602e60248201527f4e6f6e46756e6769626c65546f6b656e3a206d75737420686176652061646d6960448201526d1b881c9bdb19481d1bc81b5a5b9d60921b6064820152608401610989565b60168054911515600160a81b0260ff60a81b19909216919091179055565b610b4b83838361170b565b610b4b83838360405180602001604052806000815250611270565b6000546001600160a01b0316331480610cc157506016546001600160a01b031633145b610cdd5760405162461bcd60e51b81526004016109899061282f565b601654600160b01b900460ff1615610d425760405162461bcd60e51b815260206004820152602260248201527f4e6f6e46756e6769626c65546f6b656e3a20616c72656164792066726f7a656e604482015261202160f01b6064820152608401610989565b6016805460ff60b01b1916600160b01b179055565b6000546001600160a01b0316331480610d7a57506016546001600160a01b031633145b610d965760405162461bcd60e51b8152600401610989906128aa565b60005b8151811015610e6e5760026000838381518110610dc657634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b031682528101919091526040016000205460ff1615610e0457600e54610e009060016118fb565b600e555b600060026000848481518110610e2a57634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b03168252810191909152604001600020805460ff191691151591909117905580610e66816129ea565b915050610d99565b5050565b6016546001600160a01b0316336001600160a01b03161480610e9e57506000546001600160a01b031633145b610eba5760405162461bcd60e51b81526004016109899061287d565b601355565b6016546001600160a01b0316336001600160a01b03161480610eeb57506000546001600160a01b031633145b610f075760405162461bcd60e51b81526004016109899061287d565b60168054911515600160a01b0260ff60a01b19909216919091179055565b6000610f308261193d565b5192915050565b6000546001600160a01b03163314610f615760405162461bcd60e51b8152600401610989906128aa565b601580546001600160a01b0319166001600160a01b0392909216919091179055565b6060600780546109fb906129af565b6016546001600160a01b0316336001600160a01b03161480610fbe57506000546001600160a01b031633145b610fda5760405162461bcd60e51b81526004016109899061287d565b601680546001600160a01b0319166001600160a01b0392909216919091179055565b60006001600160a01b038216611025576040516323d3ad8160e21b815260040160405180910390fd5b506001600160a01b031660009081526009602052604090205467ffffffffffffffff1690565b6000546001600160a01b031633146110a55760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610989565b6110af6000611a66565b565b6000546001600160a01b03163314806110d457506016546001600160a01b031633145b6111205760405162461bcd60e51b815260206004820152601b60248201527f4552524f523a206d75737420686176652061646d696e20726f6c6500000000006044820152606401610989565b601654600160a81b900460ff166111715760405162461bcd60e51b81526020600482015260156024820152744d696e74696e67206e6f7420656e61626c6564202160581b6044820152606401610989565b60005b8151811015610e6e576111af8282815181106111a057634e487b7160e01b600052603260045260246000fd5b60200260200101516001611ab6565b806111b9816129ea565b915050611174565b6060600680546109fb906129af565b6109e93382611ad0565b6001600160a01b0382163314156112045760405163b06307db60e01b815260040160405180910390fd5b336000818152600b602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b61127b84848461170b565b61128d836001600160a01b0316611e2d565b80156112a257506112a084848484611e64565b155b156112c0576040516368d2bf6b60e11b815260040160405180910390fd5b50505050565b6000546001600160a01b03163314806112e957506016546001600160a01b031633145b6113055760405162461bcd60e51b8152600401610989906128aa565b60005b8151811015610e6e576002600083838151811061133557634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b031682528101919091526040016000205460ff1661137257600e5461136e906001612921565b600e555b60016002600084848151811061139857634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b03168252810191909152604001600020805460ff1916911515919091179055806113d4816129ea565b915050611308565b60606113e782611676565b61140457604051630a14c4b560e41b815260040160405180910390fd5b600061140e610f83565b905080516000141561142f576040518060200160405280600081525061145a565b8061143984611f58565b60405160200161144a929190612766565b6040516020818303038152906040525b9392505050565b6016546001600160a01b0316336001600160a01b0316148061148d57506000546001600160a01b031633145b6114a95760405162461bcd60e51b81526004016109899061287d565b601155565b6000546001600160a01b03163314806114d157506016546001600160a01b031633145b6114ed5760405162461bcd60e51b81526004016109899061282f565b601255565b60606114fc610f83565b60405160200161150c91906127a5565b604051602081830303815290604052905090565b6001600160a01b039182166000908152600b6020908152604080832093909416825291909152205460ff1690565b6016546001600160a01b0316336001600160a01b0316148061157a57506000546001600160a01b031633145b6115965760405162461bcd60e51b81526004016109899061287d565b601055565b6000546001600160a01b031633146115f55760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610989565b6001600160a01b03811661165a5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610989565b6109e981611a66565b8051610e6e90600790602084019061236c565b60008160011115801561168a575060035482105b8015610944575050600090815260086020526040902054600160e01b900460ff161590565b6000828152600a602052604080822080546001600160a01b0319166001600160a01b0387811691821790925591518593918516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591a4505050565b60006117168261193d565b9050836001600160a01b031681600001516001600160a01b03161461174d5760405162a1148160e81b815260040160405180910390fd5b6000336001600160a01b038616148061176b575061176b8533611520565b8061178657503361177b84610a7e565b6001600160a01b0316145b9050806117a657604051632ce44b5f60e11b815260040160405180910390fd5b6001600160a01b0384166117cd57604051633a954ecd60e21b815260040160405180910390fd5b6117d9600084876116af565b6001600160a01b038581166000908152600960209081526040808320805467ffffffffffffffff1980821667ffffffffffffffff92831660001901831617909255898616808652838620805493841693831660019081018416949094179055898652600890945282852080546001600160e01b031916909417600160a01b429092169190910217835587018084529220805491939091166118af5760035482146118af578054602086015167ffffffffffffffff16600160a01b026001600160e01b03199091166001600160a01b038a16171781555b50505082846001600160a01b0316866001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a45b5050505050565b600061145a83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250612072565b6040805160608101825260008082526020820181905291810191909152818060011115801561196d575060035481105b15611a4d57600081815260086020908152604091829020825160608101845290546001600160a01b0381168252600160a01b810467ffffffffffffffff1692820192909252600160e01b90910460ff16151591810182905290611a4b5780516001600160a01b0316156119e1579392505050565b5060001901600081815260086020908152604091829020825160608101845290546001600160a01b038116808352600160a01b820467ffffffffffffffff1693830193909352600160e01b900460ff1615159281019290925215611a46579392505050565b6119e1565b505b604051636f96cda160e11b815260040160405180910390fd5b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b610e6e8282604051806020016040528060008152506120ac565b601654600160a81b900460ff16611b215760405162461bcd60e51b81526020600482015260156024820152744d696e74696e67206e6f7420656e61626c6564202160581b6044820152606401610989565b6001600160a01b03821660009081526002602052604090205460ff1680611b525750601654600160a01b900460ff16155b611b975760405162461bcd60e51b815260206004820152601660248201527555736572206e6f742077686974656c6973746564202160501b6044820152606401610989565b601154811115611be95760405162461bcd60e51b815260206004820152601960248201527f6d61785065725472616e73616374696f6e2072656163686564000000000000006044820152606401610989565b600454600354600091900360001901600f54909150611c0882846120b9565b1115611c4b5760405162461bcd60e51b815260206004820152601260248201527113585e081cdd5c1c1b1e481c995858da195960721b6044820152606401610989565b60125433600090815260146020526040902054611c6890846120b9565b1115611cb65760405162461bcd60e51b815260206004820152601a60248201527f4d6178204e46547320726561636865642062792077616c6c65740000000000006044820152606401610989565b601354611cc382846120b9565b1115611de457601054611cd69083612118565b341015611d195760405162461bcd60e51b8152602060048201526011602482015270496e73756666696369656e74206665657360781b6044820152606401610989565b6015546040516000916001600160a01b03169034908381818185875af1925050503d8060008114611d66576040519150601f19603f3d011682016040523d82523d6000602084013e611d6b565b606091505b5050905080611de25760405162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152608401610989565b505b600d54611df190346120b9565b600d55611dfe8383611ab6565b33600090815260146020526040902054611e1890836120b9565b33600090815260146020526040902055505050565b6000813f7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a4708115801590610bcc5750141592915050565b604051630a85bd0160e11b81526000906001600160a01b0385169063150b7a0290611e999033908990889088906004016127df565b602060405180830381600087803b158015611eb357600080fd5b505af1925050508015611ee3575060408051601f3d908101601f19168201909252611ee0918101906126c0565b60015b611f3e573d808015611f11576040519150601f19603f3d011682016040523d82523d6000602084013e611f16565b606091505b508051611f36576040516368d2bf6b60e11b815260040160405180910390fd5b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050610bcc565b606081611f7c5750506040805180820190915260018152600360fc1b602082015290565b8160005b8115611fa65780611f90816129ea565b9150611f9f9050600a83612939565b9150611f80565b60008167ffffffffffffffff811115611fcf57634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f191660200182016040528015611ff9576020820181803683370190505b5090505b8415610bcc5761200e60018361296c565b915061201b600a86612a05565b612026906030612921565b60f81b81838151811061204957634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a90535061206b600a86612939565b9450611ffd565b600081848411156120965760405162461bcd60e51b8152600401610989919061281c565b5060006120a3848661296c565b95945050505050565b610b4b8383836001612197565b6000806120c68385612921565b90508381101561145a5760405162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f7700000000006044820152606401610989565b60008261212757506000610944565b6000612133838561294d565b9050826121408583612939565b1461145a5760405162461bcd60e51b815260206004820152602160248201527f536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f6044820152607760f81b6064820152608401610989565b6003546001600160a01b0385166121c057604051622e076360e81b815260040160405180910390fd5b836121de5760405163b562e8dd60e01b815260040160405180910390fd5b6001600160a01b038516600081815260096020908152604080832080546fffffffffffffffffffffffffffffffff19811667ffffffffffffffff8083168c0181169182176801000000000000000067ffffffffffffffff1990941690921783900481168c01811690920217909155858452600890925290912080546001600160e01b031916909217600160a01b4290921691909102179055808085018380156122945750612294876001600160a01b0316611e2d565b1561231d575b60405182906001600160a01b038916906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a46122e56000888480600101955088611e64565b612302576040516368d2bf6b60e11b815260040160405180910390fd5b8082141561229a57826003541461231857600080fd5b612363565b5b6040516001830192906001600160a01b038916906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a48082141561231e575b506003556118f4565b828054612378906129af565b90600052602060002090601f01602090048101928261239a57600085556123e0565b82601f106123b357805160ff19168380011785556123e0565b828001600101855582156123e0579182015b828111156123e05782518255916020019190600101906123c5565b506123ec9291506123f0565b5090565b5b808211156123ec57600081556001016123f1565b600067ffffffffffffffff83111561241f5761241f612a45565b612432601f8401601f19166020016128f0565b905082815283838301111561244657600080fd5b828260208301376000602084830101529392505050565b80356001600160a01b038116811461247457600080fd5b919050565b8035801515811461247457600080fd5b60006020828403121561249a578081fd5b61145a8261245d565b600080604083850312156124b5578081fd5b6124be8361245d565b91506124cc6020840161245d565b90509250929050565b6000806000606084860312156124e9578081fd5b6124f28461245d565b92506125006020850161245d565b9150604084013590509250925092565b60008060008060808587031215612525578081fd5b61252e8561245d565b935061253c6020860161245d565b925060408501359150606085013567ffffffffffffffff81111561255e578182fd5b8501601f8101871361256e578182fd5b61257d87823560208401612405565b91505092959194509250565b6000806040838503121561259b578182fd5b6125a48361245d565b91506124cc60208401612479565b600080604083850312156125c4578182fd5b6125cd8361245d565b946020939093013593505050565b600060208083850312156125ed578182fd5b823567ffffffffffffffff80821115612604578384fd5b818501915085601f830112612617578384fd5b81358181111561262957612629612a45565b8060051b915061263a8483016128f0565b8181528481019084860184860187018a1015612654578788fd5b8795505b8386101561267d576126698161245d565b835260019590950194918601918601612658565b5098975050505050505050565b60006020828403121561269b578081fd5b61145a82612479565b6000602082840312156126b5578081fd5b813561145a81612a5b565b6000602082840312156126d1578081fd5b815161145a81612a5b565b6000602082840312156126ed578081fd5b813567ffffffffffffffff811115612703578182fd5b8201601f81018413612713578182fd5b610bcc84823560208401612405565b600060208284031215612733578081fd5b5035919050565b60008151808452612752816020860160208601612983565b601f01601f19169290920160200192915050565b60008351612778818460208801612983565b83519083019061278c818360208801612983565b64173539b7b760d91b9101908152600501949350505050565b600082516127b7818460208701612983565b7531b7b73a3930b1ba16b6b2ba30b230ba30973539b7b760511b920191825250601601919050565b6001600160a01b03858116825284166020820152604081018390526080606082018190526000906128129083018461273a565b9695505050505050565b60208152600061145a602083018461273a565b6020808252602e908201527f4e6f6e46756e6769626c65546f6b656e3a206d7573742068617665204445464160408201526d554c545f41444d494e5f524f4c4560901b606082015260800190565b60208082526013908201527227b7363c9030b236b4b71037b91037bbb732b960691b604082015260600190565b60208082526026908201527f4e6f6e46756e6769626c65546f6b656e3a206d75737420686176652061646d696040820152656e20726f6c6560d01b606082015260800190565b604051601f8201601f1916810167ffffffffffffffff8111828210171561291957612919612a45565b604052919050565b6000821982111561293457612934612a19565b500190565b60008261294857612948612a2f565b500490565b600081600019048311821515161561296757612967612a19565b500290565b60008282101561297e5761297e612a19565b500390565b60005b8381101561299e578181015183820152602001612986565b838111156112c05750506000910152565b600181811c908216806129c357607f821691505b602082108114156129e457634e487b7160e01b600052602260045260246000fd5b50919050565b60006000198214156129fe576129fe612a19565b5060010190565b600082612a1457612a14612a2f565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160e01b0319811681146109e957600080fdfea2646970667358221220cb6ce488ca170d363377e586ed6caae0a5930a77edefffe14ea7098683dc58c064736f6c63430008040033000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000016466f782047656e6573697320436f6c6c656374696f6e00000000000000000000000000000000000000000000000000000000000000000000000000000000000346474300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007697066733a2f2f00000000000000000000000000000000000000000000000000

Deployed ByteCode

0x6080604052600436106102c95760003560e01c80636352211e11610175578063a22cb465116100dc578063d111515d11610095578063e985e9c51161006f578063e985e9c51461086f578063eddd0d9c1461088f578063f2fde38b146108af578063f851a440146108cf57600080fd5b8063d111515d14610819578063e268e4d31461083a578063e8a3d4851461085a57600080fd5b8063a22cb46514610763578063a92ba3c714610783578063b88d4fde14610799578063bd8aa780146107b9578063c87b56dd146107d9578063ccfdd2f8146107f957600080fd5b8063715018a61161012e578063715018a6146106c7578063729ad39e146106dc5780638da5cb5b146106fc57806395d89b411461071a5780639fd6db121461072f578063a0712d681461075057600080fd5b80636352211e1461061c57806364e39b871461063c5780636605ff661461065c5780636c0360eb14610672578063704b6c021461068757806370a08231146106a757600080fd5b806321775c92116102345780634b980d67116101ed57806355adffd1116101c757806355adffd1146105a35780635b0c29eb146105c35780635c975abb146105e45780636082adf8146105fc57600080fd5b80634b980d6714610558578063539d5c871461056e578063548db1741461058357600080fd5b806321775c92146104ac5780632194f3a2146104cc57806323b872dd146104ec57806342842e0e1461050c578063453c23101461052c578063485a68a31461054257600080fd5b806313966db51161028657806313966db5146103c357806313af4035146103d9578063150b7a02146103f957806318160ddd146104325780631e7269c51461044f5780631e7be2101461047c57600080fd5b806301ffc9a7146102ce57806302fe53051461030357806306fdde0314610325578063081812fc14610347578063095ea7b31461037f5780630ba133c51461039f575b600080fd5b3480156102da57600080fd5b506102ee6102e93660046126a4565b6108ef565b60405190151581526020015b60405180910390f35b34801561030f57600080fd5b5061032361031e3660046126dc565b61094a565b005b34801561033157600080fd5b5061033a6109ec565b6040516102fa919061281c565b34801561035357600080fd5b50610367610362366004612722565b610a7e565b6040516001600160a01b0390911681526020016102fa565b34801561038b57600080fd5b5061032361039a3660046125b2565b610ac2565b3480156103ab57600080fd5b506103b5600f5481565b6040519081526020016102fa565b3480156103cf57600080fd5b506103b560105481565b3480156103e557600080fd5b506103236103f4366004612489565b610b50565b34801561040557600080fd5b50610419610414366004612510565b610b83565b6040516001600160e01b031990911681526020016102fa565b34801561043e57600080fd5b5060045460035403600019016103b5565b34801561045b57600080fd5b506103b561046a366004612489565b60146020526000908152604090205481565b34801561048857600080fd5b506102ee610497366004612489565b60026020526000908152604090205460ff1681565b3480156104b857600080fd5b506103236104c736600461268a565b610bd4565b3480156104d857600080fd5b50601554610367906001600160a01b031681565b3480156104f857600080fd5b506103236105073660046124d5565b610c78565b34801561051857600080fd5b506103236105273660046124d5565b610c83565b34801561053857600080fd5b506103b560125481565b34801561054e57600080fd5b506103b560135481565b34801561056457600080fd5b506103b560115481565b34801561057a57600080fd5b50610323610c9e565b34801561058f57600080fd5b5061032361059e3660046125db565b610d57565b3480156105af57600080fd5b506103236105be366004612722565b610e72565b3480156105cf57600080fd5b506016546102ee90600160a01b900460ff1681565b3480156105f057600080fd5b50600c5460ff166102ee565b34801561060857600080fd5b5061032361061736600461268a565b610ebf565b34801561062857600080fd5b50610367610637366004612722565b610f25565b34801561064857600080fd5b50610323610657366004612489565b610f37565b34801561066857600080fd5b506103b5600d5481565b34801561067e57600080fd5b5061033a610f83565b34801561069357600080fd5b506103236106a2366004612489565b610f92565b3480156106b357600080fd5b506103b56106c2366004612489565b610ffc565b3480156106d357600080fd5b5061032361104b565b3480156106e857600080fd5b506103236106f73660046125db565b6110b1565b34801561070857600080fd5b506000546001600160a01b0316610367565b34801561072657600080fd5b5061033a6111c1565b34801561073b57600080fd5b506016546102ee90600160a81b900460ff1681565b61032361075e366004612722565b6111d0565b34801561076f57600080fd5b5061032361077e366004612589565b6111da565b34801561078f57600080fd5b506103b5600e5481565b3480156107a557600080fd5b506103236107b4366004612510565b611270565b3480156107c557600080fd5b506103236107d43660046125db565b6112c6565b3480156107e557600080fd5b5061033a6107f4366004612722565b6113dc565b34801561080557600080fd5b50610323610814366004612722565b611461565b34801561082557600080fd5b506016546102ee90600160b01b900460ff1681565b34801561084657600080fd5b50610323610855366004612722565b6114ae565b34801561086657600080fd5b5061033a6114f2565b34801561087b57600080fd5b506102ee61088a3660046124a3565b611520565b34801561089b57600080fd5b506103236108aa366004612722565b61154e565b3480156108bb57600080fd5b506103236108ca366004612489565b61159b565b3480156108db57600080fd5b50601654610367906001600160a01b031681565b60006001600160e01b031982166380ac58cd60e01b148061092057506001600160e01b03198216635b5e139f60e01b145b8061094457506001600160e01b0319821660009081526001602052604090205460ff165b92915050565b6000546001600160a01b031633148061096d57506016546001600160a01b031633145b6109925760405162461bcd60e51b8152600401610989906128aa565b60405180910390fd5b601654600160b01b900460ff16156109e05760405162461bcd60e51b81526020600482015260116024820152704d657461646174612066726f7a656e202160781b6044820152606401610989565b6109e981611663565b50565b6060600580546109fb906129af565b80601f0160208091040260200160405190810160405280929190818152602001828054610a27906129af565b8015610a745780601f10610a4957610100808354040283529160200191610a74565b820191906000526020600020905b815481529060010190602001808311610a5757829003601f168201915b5050505050905090565b6000610a8982611676565b610aa6576040516333d1c03960e21b815260040160405180910390fd5b506000908152600a60205260409020546001600160a01b031690565b6000610acd82610f25565b9050806001600160a01b0316836001600160a01b03161415610b025760405163250fdee360e21b815260040160405180910390fd5b336001600160a01b03821614801590610b225750610b208133611520565b155b15610b40576040516367d9dca160e11b815260040160405180910390fd5b610b4b8383836116af565b505050565b6000546001600160a01b03163314610b7a5760405162461bcd60e51b8152600401610989906128aa565b6109e98161159b565b60007fa05d90f300156ad1b545bc5d8197024456f21d22a708f5af04dd293e3d60525185858585604051610bba94939291906127df565b60405180910390a150630a85bd0160e11b5b949350505050565b6000546001600160a01b0316331480610bf757506016546001600160a01b031633145b610c5a5760405162461bcd60e51b815260206004820152602e60248201527f4e6f6e46756e6769626c65546f6b656e3a206d75737420686176652061646d6960448201526d1b881c9bdb19481d1bc81b5a5b9d60921b6064820152608401610989565b60168054911515600160a81b0260ff60a81b19909216919091179055565b610b4b83838361170b565b610b4b83838360405180602001604052806000815250611270565b6000546001600160a01b0316331480610cc157506016546001600160a01b031633145b610cdd5760405162461bcd60e51b81526004016109899061282f565b601654600160b01b900460ff1615610d425760405162461bcd60e51b815260206004820152602260248201527f4e6f6e46756e6769626c65546f6b656e3a20616c72656164792066726f7a656e604482015261202160f01b6064820152608401610989565b6016805460ff60b01b1916600160b01b179055565b6000546001600160a01b0316331480610d7a57506016546001600160a01b031633145b610d965760405162461bcd60e51b8152600401610989906128aa565b60005b8151811015610e6e5760026000838381518110610dc657634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b031682528101919091526040016000205460ff1615610e0457600e54610e009060016118fb565b600e555b600060026000848481518110610e2a57634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b03168252810191909152604001600020805460ff191691151591909117905580610e66816129ea565b915050610d99565b5050565b6016546001600160a01b0316336001600160a01b03161480610e9e57506000546001600160a01b031633145b610eba5760405162461bcd60e51b81526004016109899061287d565b601355565b6016546001600160a01b0316336001600160a01b03161480610eeb57506000546001600160a01b031633145b610f075760405162461bcd60e51b81526004016109899061287d565b60168054911515600160a01b0260ff60a01b19909216919091179055565b6000610f308261193d565b5192915050565b6000546001600160a01b03163314610f615760405162461bcd60e51b8152600401610989906128aa565b601580546001600160a01b0319166001600160a01b0392909216919091179055565b6060600780546109fb906129af565b6016546001600160a01b0316336001600160a01b03161480610fbe57506000546001600160a01b031633145b610fda5760405162461bcd60e51b81526004016109899061287d565b601680546001600160a01b0319166001600160a01b0392909216919091179055565b60006001600160a01b038216611025576040516323d3ad8160e21b815260040160405180910390fd5b506001600160a01b031660009081526009602052604090205467ffffffffffffffff1690565b6000546001600160a01b031633146110a55760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610989565b6110af6000611a66565b565b6000546001600160a01b03163314806110d457506016546001600160a01b031633145b6111205760405162461bcd60e51b815260206004820152601b60248201527f4552524f523a206d75737420686176652061646d696e20726f6c6500000000006044820152606401610989565b601654600160a81b900460ff166111715760405162461bcd60e51b81526020600482015260156024820152744d696e74696e67206e6f7420656e61626c6564202160581b6044820152606401610989565b60005b8151811015610e6e576111af8282815181106111a057634e487b7160e01b600052603260045260246000fd5b60200260200101516001611ab6565b806111b9816129ea565b915050611174565b6060600680546109fb906129af565b6109e93382611ad0565b6001600160a01b0382163314156112045760405163b06307db60e01b815260040160405180910390fd5b336000818152600b602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b61127b84848461170b565b61128d836001600160a01b0316611e2d565b80156112a257506112a084848484611e64565b155b156112c0576040516368d2bf6b60e11b815260040160405180910390fd5b50505050565b6000546001600160a01b03163314806112e957506016546001600160a01b031633145b6113055760405162461bcd60e51b8152600401610989906128aa565b60005b8151811015610e6e576002600083838151811061133557634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b031682528101919091526040016000205460ff1661137257600e5461136e906001612921565b600e555b60016002600084848151811061139857634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b03168252810191909152604001600020805460ff1916911515919091179055806113d4816129ea565b915050611308565b60606113e782611676565b61140457604051630a14c4b560e41b815260040160405180910390fd5b600061140e610f83565b905080516000141561142f576040518060200160405280600081525061145a565b8061143984611f58565b60405160200161144a929190612766565b6040516020818303038152906040525b9392505050565b6016546001600160a01b0316336001600160a01b0316148061148d57506000546001600160a01b031633145b6114a95760405162461bcd60e51b81526004016109899061287d565b601155565b6000546001600160a01b03163314806114d157506016546001600160a01b031633145b6114ed5760405162461bcd60e51b81526004016109899061282f565b601255565b60606114fc610f83565b60405160200161150c91906127a5565b604051602081830303815290604052905090565b6001600160a01b039182166000908152600b6020908152604080832093909416825291909152205460ff1690565b6016546001600160a01b0316336001600160a01b0316148061157a57506000546001600160a01b031633145b6115965760405162461bcd60e51b81526004016109899061287d565b601055565b6000546001600160a01b031633146115f55760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610989565b6001600160a01b03811661165a5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610989565b6109e981611a66565b8051610e6e90600790602084019061236c565b60008160011115801561168a575060035482105b8015610944575050600090815260086020526040902054600160e01b900460ff161590565b6000828152600a602052604080822080546001600160a01b0319166001600160a01b0387811691821790925591518593918516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591a4505050565b60006117168261193d565b9050836001600160a01b031681600001516001600160a01b03161461174d5760405162a1148160e81b815260040160405180910390fd5b6000336001600160a01b038616148061176b575061176b8533611520565b8061178657503361177b84610a7e565b6001600160a01b0316145b9050806117a657604051632ce44b5f60e11b815260040160405180910390fd5b6001600160a01b0384166117cd57604051633a954ecd60e21b815260040160405180910390fd5b6117d9600084876116af565b6001600160a01b038581166000908152600960209081526040808320805467ffffffffffffffff1980821667ffffffffffffffff92831660001901831617909255898616808652838620805493841693831660019081018416949094179055898652600890945282852080546001600160e01b031916909417600160a01b429092169190910217835587018084529220805491939091166118af5760035482146118af578054602086015167ffffffffffffffff16600160a01b026001600160e01b03199091166001600160a01b038a16171781555b50505082846001600160a01b0316866001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a45b5050505050565b600061145a83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250612072565b6040805160608101825260008082526020820181905291810191909152818060011115801561196d575060035481105b15611a4d57600081815260086020908152604091829020825160608101845290546001600160a01b0381168252600160a01b810467ffffffffffffffff1692820192909252600160e01b90910460ff16151591810182905290611a4b5780516001600160a01b0316156119e1579392505050565b5060001901600081815260086020908152604091829020825160608101845290546001600160a01b038116808352600160a01b820467ffffffffffffffff1693830193909352600160e01b900460ff1615159281019290925215611a46579392505050565b6119e1565b505b604051636f96cda160e11b815260040160405180910390fd5b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b610e6e8282604051806020016040528060008152506120ac565b601654600160a81b900460ff16611b215760405162461bcd60e51b81526020600482015260156024820152744d696e74696e67206e6f7420656e61626c6564202160581b6044820152606401610989565b6001600160a01b03821660009081526002602052604090205460ff1680611b525750601654600160a01b900460ff16155b611b975760405162461bcd60e51b815260206004820152601660248201527555736572206e6f742077686974656c6973746564202160501b6044820152606401610989565b601154811115611be95760405162461bcd60e51b815260206004820152601960248201527f6d61785065725472616e73616374696f6e2072656163686564000000000000006044820152606401610989565b600454600354600091900360001901600f54909150611c0882846120b9565b1115611c4b5760405162461bcd60e51b815260206004820152601260248201527113585e081cdd5c1c1b1e481c995858da195960721b6044820152606401610989565b60125433600090815260146020526040902054611c6890846120b9565b1115611cb65760405162461bcd60e51b815260206004820152601a60248201527f4d6178204e46547320726561636865642062792077616c6c65740000000000006044820152606401610989565b601354611cc382846120b9565b1115611de457601054611cd69083612118565b341015611d195760405162461bcd60e51b8152602060048201526011602482015270496e73756666696369656e74206665657360781b6044820152606401610989565b6015546040516000916001600160a01b03169034908381818185875af1925050503d8060008114611d66576040519150601f19603f3d011682016040523d82523d6000602084013e611d6b565b606091505b5050905080611de25760405162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152608401610989565b505b600d54611df190346120b9565b600d55611dfe8383611ab6565b33600090815260146020526040902054611e1890836120b9565b33600090815260146020526040902055505050565b6000813f7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a4708115801590610bcc5750141592915050565b604051630a85bd0160e11b81526000906001600160a01b0385169063150b7a0290611e999033908990889088906004016127df565b602060405180830381600087803b158015611eb357600080fd5b505af1925050508015611ee3575060408051601f3d908101601f19168201909252611ee0918101906126c0565b60015b611f3e573d808015611f11576040519150601f19603f3d011682016040523d82523d6000602084013e611f16565b606091505b508051611f36576040516368d2bf6b60e11b815260040160405180910390fd5b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050610bcc565b606081611f7c5750506040805180820190915260018152600360fc1b602082015290565b8160005b8115611fa65780611f90816129ea565b9150611f9f9050600a83612939565b9150611f80565b60008167ffffffffffffffff811115611fcf57634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f191660200182016040528015611ff9576020820181803683370190505b5090505b8415610bcc5761200e60018361296c565b915061201b600a86612a05565b612026906030612921565b60f81b81838151811061204957634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a90535061206b600a86612939565b9450611ffd565b600081848411156120965760405162461bcd60e51b8152600401610989919061281c565b5060006120a3848661296c565b95945050505050565b610b4b8383836001612197565b6000806120c68385612921565b90508381101561145a5760405162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f7700000000006044820152606401610989565b60008261212757506000610944565b6000612133838561294d565b9050826121408583612939565b1461145a5760405162461bcd60e51b815260206004820152602160248201527f536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f6044820152607760f81b6064820152608401610989565b6003546001600160a01b0385166121c057604051622e076360e81b815260040160405180910390fd5b836121de5760405163b562e8dd60e01b815260040160405180910390fd5b6001600160a01b038516600081815260096020908152604080832080546fffffffffffffffffffffffffffffffff19811667ffffffffffffffff8083168c0181169182176801000000000000000067ffffffffffffffff1990941690921783900481168c01811690920217909155858452600890925290912080546001600160e01b031916909217600160a01b4290921691909102179055808085018380156122945750612294876001600160a01b0316611e2d565b1561231d575b60405182906001600160a01b038916906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a46122e56000888480600101955088611e64565b612302576040516368d2bf6b60e11b815260040160405180910390fd5b8082141561229a57826003541461231857600080fd5b612363565b5b6040516001830192906001600160a01b038916906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a48082141561231e575b506003556118f4565b828054612378906129af565b90600052602060002090601f01602090048101928261239a57600085556123e0565b82601f106123b357805160ff19168380011785556123e0565b828001600101855582156123e0579182015b828111156123e05782518255916020019190600101906123c5565b506123ec9291506123f0565b5090565b5b808211156123ec57600081556001016123f1565b600067ffffffffffffffff83111561241f5761241f612a45565b612432601f8401601f19166020016128f0565b905082815283838301111561244657600080fd5b828260208301376000602084830101529392505050565b80356001600160a01b038116811461247457600080fd5b919050565b8035801515811461247457600080fd5b60006020828403121561249a578081fd5b61145a8261245d565b600080604083850312156124b5578081fd5b6124be8361245d565b91506124cc6020840161245d565b90509250929050565b6000806000606084860312156124e9578081fd5b6124f28461245d565b92506125006020850161245d565b9150604084013590509250925092565b60008060008060808587031215612525578081fd5b61252e8561245d565b935061253c6020860161245d565b925060408501359150606085013567ffffffffffffffff81111561255e578182fd5b8501601f8101871361256e578182fd5b61257d87823560208401612405565b91505092959194509250565b6000806040838503121561259b578182fd5b6125a48361245d565b91506124cc60208401612479565b600080604083850312156125c4578182fd5b6125cd8361245d565b946020939093013593505050565b600060208083850312156125ed578182fd5b823567ffffffffffffffff80821115612604578384fd5b818501915085601f830112612617578384fd5b81358181111561262957612629612a45565b8060051b915061263a8483016128f0565b8181528481019084860184860187018a1015612654578788fd5b8795505b8386101561267d576126698161245d565b835260019590950194918601918601612658565b5098975050505050505050565b60006020828403121561269b578081fd5b61145a82612479565b6000602082840312156126b5578081fd5b813561145a81612a5b565b6000602082840312156126d1578081fd5b815161145a81612a5b565b6000602082840312156126ed578081fd5b813567ffffffffffffffff811115612703578182fd5b8201601f81018413612713578182fd5b610bcc84823560208401612405565b600060208284031215612733578081fd5b5035919050565b60008151808452612752816020860160208601612983565b601f01601f19169290920160200192915050565b60008351612778818460208801612983565b83519083019061278c818360208801612983565b64173539b7b760d91b9101908152600501949350505050565b600082516127b7818460208701612983565b7531b7b73a3930b1ba16b6b2ba30b230ba30973539b7b760511b920191825250601601919050565b6001600160a01b03858116825284166020820152604081018390526080606082018190526000906128129083018461273a565b9695505050505050565b60208152600061145a602083018461273a565b6020808252602e908201527f4e6f6e46756e6769626c65546f6b656e3a206d7573742068617665204445464160408201526d554c545f41444d494e5f524f4c4560901b606082015260800190565b60208082526013908201527227b7363c9030b236b4b71037b91037bbb732b960691b604082015260600190565b60208082526026908201527f4e6f6e46756e6769626c65546f6b656e3a206d75737420686176652061646d696040820152656e20726f6c6560d01b606082015260800190565b604051601f8201601f1916810167ffffffffffffffff8111828210171561291957612919612a45565b604052919050565b6000821982111561293457612934612a19565b500190565b60008261294857612948612a2f565b500490565b600081600019048311821515161561296757612967612a19565b500290565b60008282101561297e5761297e612a19565b500390565b60005b8381101561299e578181015183820152602001612986565b838111156112c05750506000910152565b600181811c908216806129c357607f821691505b602082108114156129e457634e487b7160e01b600052602260045260246000fd5b50919050565b60006000198214156129fe576129fe612a19565b5060010190565b600082612a1457612a14612a2f565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160e01b0319811681146109e957600080fdfea2646970667358221220cb6ce488ca170d363377e586ed6caae0a5930a77edefffe14ea7098683dc58c064736f6c63430008040033