ETH Price: $3,365.36 (-1.50%)
Gas: 7 Gwei

Token

Desperate ApeWives (DAW)
 

Overview

Max Total Supply

10,000 DAW

Holders

3,655

Market

Volume (24H)

0.0283 ETH

Min Price (24H)

$95.24 @ 0.028300 ETH

Max Price (24H)

$95.24 @ 0.028300 ETH
Filtered by Token Holder
slotty.eth
Balance
3 DAW
0x4efC2FBE5Ea2321675d8897F6C6E6e33c1d2D342
Loading...
Loading
Loading...
Loading
Loading...
Loading

OVERVIEW

Inspired by the award winning television series “The Desperate Housewives”, DAW is a collection of 10,000 Desperate ApeWives NFTs.

# Exchange Pair Price  24H Volume % Volume

Contract Source Code Verified (Exact Match)

Contract Name:
DesperateApeWives

Compiler Version
v0.8.2+commit.661d1103

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion, MIT license
File 1 of 15 : Ownable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../utils/Context.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 2 of 15 : PaymentSplitter.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../utils/Address.sol";
import "../utils/Context.sol";
import "../utils/math/SafeMath.sol";

/**
 * @title PaymentSplitter
 * @dev This contract allows to split Ether payments among a group of accounts. The sender does not need to be aware
 * that the Ether will be split in this way, since it is handled transparently by the contract.
 *
 * The split can be in equal parts or in any other arbitrary proportion. The way this is specified is by assigning each
 * account to a number of shares. Of all the Ether that this contract receives, each account will then be able to claim
 * an amount proportional to the percentage of total shares they were assigned.
 *
 * `PaymentSplitter` follows a _pull payment_ model. This means that payments are not automatically forwarded to the
 * accounts but kept in this contract, and the actual transfer is triggered as a separate step by calling the {release}
 * function.
 */
contract PaymentSplitter is Context {
    event PayeeAdded(address account, uint256 shares);
    event PaymentReleased(address to, uint256 amount);
    event PaymentReceived(address from, uint256 amount);

    uint256 private _totalShares;
    uint256 private _totalReleased;

    mapping(address => uint256) private _shares;
    mapping(address => uint256) private _released;
    address[] private _payees;

    /**
     * @dev Creates an instance of `PaymentSplitter` where each account in `payees` is assigned the number of shares at
     * the matching position in the `shares` array.
     *
     * All addresses in `payees` must be non-zero. Both arrays must have the same non-zero length, and there must be no
     * duplicates in `payees`.
     */
    constructor(address[] memory payees, uint256[] memory shares_) payable {
        require(payees.length == shares_.length, "PaymentSplitter: payees and shares length mismatch");
        require(payees.length > 0, "PaymentSplitter: no payees");

        for (uint256 i = 0; i < payees.length; i++) {
            _addPayee(payees[i], shares_[i]);
        }
    }

    /**
     * @dev The Ether received will be logged with {PaymentReceived} events. Note that these events are not fully
     * reliable: it's possible for a contract to receive Ether without triggering this function. This only affects the
     * reliability of the events, and not the actual splitting of Ether.
     *
     * To learn more about this see the Solidity documentation for
     * https://solidity.readthedocs.io/en/latest/contracts.html#fallback-function[fallback
     * functions].
     */
    receive() external payable virtual {
        emit PaymentReceived(_msgSender(), msg.value);
    }

    /**
     * @dev Getter for the total shares held by payees.
     */
    function totalShares() public view returns (uint256) {
        return _totalShares;
    }

    /**
     * @dev Getter for the total amount of Ether already released.
     */
    function totalReleased() public view returns (uint256) {
        return _totalReleased;
    }

    /**
     * @dev Getter for the amount of shares held by an account.
     */
    function shares(address account) public view returns (uint256) {
        return _shares[account];
    }

    /**
     * @dev Getter for the amount of Ether already released to a payee.
     */
    function released(address account) public view returns (uint256) {
        return _released[account];
    }

    /**
     * @dev Getter for the address of the payee number `index`.
     */
    function payee(uint256 index) public view returns (address) {
        return _payees[index];
    }

    /**
     * @dev Triggers a transfer to `account` of the amount of Ether they are owed, according to their percentage of the
     * total shares and their previous withdrawals.
     */
    function release(address payable account) public virtual {
        require(_shares[account] > 0, "PaymentSplitter: account has no shares");

        uint256 totalReceived = address(this).balance + _totalReleased;
        uint256 payment = (totalReceived * _shares[account]) / _totalShares - _released[account];

        require(payment != 0, "PaymentSplitter: account is not due payment");

        _released[account] = _released[account] + payment;
        _totalReleased = _totalReleased + payment;

        Address.sendValue(account, payment);
        emit PaymentReleased(account, payment);
    }

    /**
     * @dev Add a new payee to the contract.
     * @param account The address of the payee to add.
     * @param shares_ The number of shares owned by the payee.
     */
    function _addPayee(address account, uint256 shares_) private {
        require(account != address(0), "PaymentSplitter: account is the zero address");
        require(shares_ > 0, "PaymentSplitter: shares are 0");
        require(_shares[account] == 0, "PaymentSplitter: account already has shares");

        _payees.push(account);
        _shares[account] = shares_;
        _totalShares = _totalShares + shares_;
        emit PayeeAdded(account, shares_);
    }
}

File 3 of 15 : ERC721.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./IERC721.sol";
import "./IERC721Receiver.sol";
import "./extensions/IERC721Metadata.sol";
import "../../utils/Address.sol";
import "../../utils/Context.sol";
import "../../utils/Strings.sol";
import "../../utils/introspection/ERC165.sol";

/**
 * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including
 * the Metadata extension, but not including the Enumerable extension, which is available separately as
 * {ERC721Enumerable}.
 */
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata {
    using Address for address;
    using Strings for uint256;

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

    // Mapping from token ID to owner address
    mapping(uint256 => address) private _owners;

    // Mapping owner address to token count
    mapping(address => uint256) private _balances;

    // 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;

    /**
     * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection.
     */
    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
    }

    /**
     * @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 virtual override returns (uint256) {
        require(owner != address(0), "ERC721: balance query for the zero address");
        return _balances[owner];
    }

    /**
     * @dev See {IERC721-ownerOf}.
     */
    function ownerOf(uint256 tokenId) public view virtual override returns (address) {
        address owner = _owners[tokenId];
        require(owner != address(0), "ERC721: owner query for nonexistent token");
        return owner;
    }

    /**
     * @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) {
        require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token");

        string memory baseURI = _baseURI();
        return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : "";
    }

    /**
     * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each
     * token will be the concatenation of the `baseURI` and the `tokenId`. Empty
     * by default, can be overriden in child contracts.
     */
    function _baseURI() internal view virtual returns (string memory) {
        return "";
    }

    /**
     * @dev See {IERC721-approve}.
     */
    function approve(address to, uint256 tokenId) public virtual override {
        address owner = ERC721.ownerOf(tokenId);
        require(to != owner, "ERC721: approval to current owner");

        require(
            _msgSender() == owner || isApprovedForAll(owner, _msgSender()),
            "ERC721: approve caller is not owner nor approved for all"
        );

        _approve(to, tokenId);
    }

    /**
     * @dev See {IERC721-getApproved}.
     */
    function getApproved(uint256 tokenId) public view virtual override returns (address) {
        require(_exists(tokenId), "ERC721: approved query for nonexistent token");

        return _tokenApprovals[tokenId];
    }

    /**
     * @dev See {IERC721-setApprovalForAll}.
     */
    function setApprovalForAll(address operator, bool approved) public virtual override {
        require(operator != _msgSender(), "ERC721: approve to caller");

        _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 {
        //solhint-disable-next-line max-line-length
        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved");

        _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 {
        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved");
        _safeTransfer(from, to, tokenId, _data);
    }

    /**
     * @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.
     *
     * `_data` is additional data, it has no specified format and it is sent in call to `to`.
     *
     * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g.
     * implement alternative mechanisms to perform token transfer, such as signature-based.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function _safeTransfer(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) internal virtual {
        _transfer(from, to, tokenId);
        require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer");
    }

    /**
     * @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`),
     * and stop existing when they are burned (`_burn`).
     */
    function _exists(uint256 tokenId) internal view virtual returns (bool) {
        return _owners[tokenId] != address(0);
    }

    /**
     * @dev Returns whether `spender` is allowed to manage `tokenId`.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) {
        require(_exists(tokenId), "ERC721: operator query for nonexistent token");
        address owner = ERC721.ownerOf(tokenId);
        return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, spender));
    }

    /**
     * @dev Safely mints `tokenId` and transfers it to `to`.
     *
     * Requirements:
     *
     * - `tokenId` must not exist.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function _safeMint(address to, uint256 tokenId) internal virtual {
        _safeMint(to, tokenId, "");
    }

    /**
     * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is
     * forwarded in {IERC721Receiver-onERC721Received} to contract recipients.
     */
    function _safeMint(
        address to,
        uint256 tokenId,
        bytes memory _data
    ) internal virtual {
        _mint(to, tokenId);
        require(
            _checkOnERC721Received(address(0), to, tokenId, _data),
            "ERC721: transfer to non ERC721Receiver implementer"
        );
    }

    /**
     * @dev Mints `tokenId` and transfers it to `to`.
     *
     * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible
     *
     * Requirements:
     *
     * - `tokenId` must not exist.
     * - `to` cannot be the zero address.
     *
     * Emits a {Transfer} event.
     */
    function _mint(address to, uint256 tokenId) internal virtual {
        require(to != address(0), "ERC721: mint to the zero address");
        require(!_exists(tokenId), "ERC721: token already minted");

        _beforeTokenTransfer(address(0), to, tokenId);

        _balances[to] += 1;
        _owners[tokenId] = to;

        emit Transfer(address(0), to, tokenId);
    }

    /**
     * @dev Destroys `tokenId`.
     * The approval is cleared when the token is burned.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     *
     * Emits a {Transfer} event.
     */
    function _burn(uint256 tokenId) internal virtual {
        address owner = ERC721.ownerOf(tokenId);

        _beforeTokenTransfer(owner, address(0), tokenId);

        // Clear approvals
        _approve(address(0), tokenId);

        _balances[owner] -= 1;
        delete _owners[tokenId];

        emit Transfer(owner, address(0), tokenId);
    }

    /**
     * @dev Transfers `tokenId` from `from` to `to`.
     *  As opposed to {transferFrom}, this imposes no restrictions on msg.sender.
     *
     * 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
    ) internal virtual {
        require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer of token that is not own");
        require(to != address(0), "ERC721: transfer to the zero address");

        _beforeTokenTransfer(from, to, tokenId);

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

        _balances[from] -= 1;
        _balances[to] += 1;
        _owners[tokenId] = to;

        emit Transfer(from, to, tokenId);
    }

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

    /**
     * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address.
     * The call is not executed if the target address is not a 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 _checkOnERC721Received(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) private returns (bool) {
        if (to.isContract()) {
            try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) {
                return retval == IERC721Receiver.onERC721Received.selector;
            } catch (bytes memory reason) {
                if (reason.length == 0) {
                    revert("ERC721: transfer to non ERC721Receiver implementer");
                } else {
                    assembly {
                        revert(add(32, reason), mload(reason))
                    }
                }
            }
        } else {
            return true;
        }
    }

    /**
     * @dev Hook that is called before any token transfer. This includes minting
     * and burning.
     *
     * 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, ``from``'s `tokenId` will be burned.
     * - `from` and `to` are never both zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {}
}

File 4 of 15 : IERC721.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../../utils/introspection/IERC165.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 5 of 15 : IERC721Receiver.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @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 6 of 15 : ERC721Enumerable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../ERC721.sol";
import "./IERC721Enumerable.sol";

/**
 * @dev This implements an optional extension of {ERC721} defined in the EIP that adds
 * enumerability of all the token ids in the contract as well as all token ids owned by each
 * account.
 */
abstract contract ERC721Enumerable is ERC721, IERC721Enumerable {
    // Mapping from owner to list of owned token IDs
    mapping(address => mapping(uint256 => uint256)) private _ownedTokens;

    // Mapping from token ID to index of the owner tokens list
    mapping(uint256 => uint256) private _ownedTokensIndex;

    // Array with all token ids, used for enumeration
    uint256[] private _allTokens;

    // Mapping from token id to position in the allTokens array
    mapping(uint256 => uint256) private _allTokensIndex;

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

    /**
     * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}.
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) public view virtual override returns (uint256) {
        require(index < ERC721.balanceOf(owner), "ERC721Enumerable: owner index out of bounds");
        return _ownedTokens[owner][index];
    }

    /**
     * @dev See {IERC721Enumerable-totalSupply}.
     */
    function totalSupply() public view virtual override returns (uint256) {
        return _allTokens.length;
    }

    /**
     * @dev See {IERC721Enumerable-tokenByIndex}.
     */
    function tokenByIndex(uint256 index) public view virtual override returns (uint256) {
        require(index < ERC721Enumerable.totalSupply(), "ERC721Enumerable: global index out of bounds");
        return _allTokens[index];
    }

    /**
     * @dev Hook that is called before any token transfer. This includes minting
     * and burning.
     *
     * 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, ``from``'s `tokenId` will be burned.
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual override {
        super._beforeTokenTransfer(from, to, tokenId);

        if (from == address(0)) {
            _addTokenToAllTokensEnumeration(tokenId);
        } else if (from != to) {
            _removeTokenFromOwnerEnumeration(from, tokenId);
        }
        if (to == address(0)) {
            _removeTokenFromAllTokensEnumeration(tokenId);
        } else if (to != from) {
            _addTokenToOwnerEnumeration(to, tokenId);
        }
    }

    /**
     * @dev Private function to add a token to this extension's ownership-tracking data structures.
     * @param to address representing the new owner of the given token ID
     * @param tokenId uint256 ID of the token to be added to the tokens list of the given address
     */
    function _addTokenToOwnerEnumeration(address to, uint256 tokenId) private {
        uint256 length = ERC721.balanceOf(to);
        _ownedTokens[to][length] = tokenId;
        _ownedTokensIndex[tokenId] = length;
    }

    /**
     * @dev Private function to add a token to this extension's token tracking data structures.
     * @param tokenId uint256 ID of the token to be added to the tokens list
     */
    function _addTokenToAllTokensEnumeration(uint256 tokenId) private {
        _allTokensIndex[tokenId] = _allTokens.length;
        _allTokens.push(tokenId);
    }

    /**
     * @dev Private function to remove a token from this extension's ownership-tracking data structures. Note that
     * while the token is not assigned a new owner, the `_ownedTokensIndex` mapping is _not_ updated: this allows for
     * gas optimizations e.g. when performing a transfer operation (avoiding double writes).
     * This has O(1) time complexity, but alters the order of the _ownedTokens array.
     * @param from address representing the previous owner of the given token ID
     * @param tokenId uint256 ID of the token to be removed from the tokens list of the given address
     */
    function _removeTokenFromOwnerEnumeration(address from, uint256 tokenId) private {
        // To prevent a gap in from's tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = ERC721.balanceOf(from) - 1;
        uint256 tokenIndex = _ownedTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary
        if (tokenIndex != lastTokenIndex) {
            uint256 lastTokenId = _ownedTokens[from][lastTokenIndex];

            _ownedTokens[from][tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
            _ownedTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index
        }

        // This also deletes the contents at the last position of the array
        delete _ownedTokensIndex[tokenId];
        delete _ownedTokens[from][lastTokenIndex];
    }

    /**
     * @dev Private function to remove a token from this extension's token tracking data structures.
     * This has O(1) time complexity, but alters the order of the _allTokens array.
     * @param tokenId uint256 ID of the token to be removed from the tokens list
     */
    function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private {
        // To prevent a gap in the tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = _allTokens.length - 1;
        uint256 tokenIndex = _allTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary. However, since this occurs so
        // rarely (when the last minted token is burnt) that we still do the swap here to avoid the gas cost of adding
        // an 'if' statement (like in _removeTokenFromOwnerEnumeration)
        uint256 lastTokenId = _allTokens[lastTokenIndex];

        _allTokens[tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
        _allTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index

        // This also deletes the contents at the last position of the array
        delete _allTokensIndex[tokenId];
        _allTokens.pop();
    }
}

File 7 of 15 : IERC721Enumerable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../IERC721.sol";

/**
 * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
interface IERC721Enumerable is IERC721 {
    /**
     * @dev Returns the total amount of tokens stored by the contract.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns a token ID owned by `owner` at a given `index` of its token list.
     * Use along with {balanceOf} to enumerate all of ``owner``'s tokens.
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) external view returns (uint256 tokenId);

    /**
     * @dev Returns a token ID at a given `index` of all the tokens stored by the contract.
     * Use along with {totalSupply} to enumerate all tokens.
     */
    function tokenByIndex(uint256 index) external view returns (uint256);
}

File 8 of 15 : IERC721Metadata.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../IERC721.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 9 of 15 : Address.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

        uint256 size;
        assembly {
            size := extcodesize(account)
        }
        return size > 0;
    }

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

        (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 10 of 15 : Context.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @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 11 of 15 : Strings.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @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 12 of 15 : ERC165.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./IERC165.sol";

/**
 * @dev Implementation of the {IERC165} interface.
 *
 * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check
 * for the additional interface id that will be supported. For example:
 *
 * ```solidity
 * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
 *     return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);
 * }
 * ```
 *
 * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation.
 */
abstract contract ERC165 is IERC165 {
    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        return interfaceId == type(IERC165).interfaceId;
    }
}

File 13 of 15 : IERC165.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

File 14 of 15 : SafeMath.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

// CAUTION
// This version of SafeMath should only be used with Solidity 0.8 or later,
// because it relies on the compiler's built in overflow checks.

/**
 * @dev Wrappers over Solidity's arithmetic operations.
 *
 * NOTE: `SafeMath` is no longer needed starting with Solidity 0.8. The compiler
 * now has built in overflow checking.
 */
library SafeMath {
    /**
     * @dev Returns the addition of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            uint256 c = a + b;
            if (c < a) return (false, 0);
            return (true, c);
        }
    }

    /**
     * @dev Returns the substraction of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b > a) return (false, 0);
            return (true, a - b);
        }
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            // 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 (true, 0);
            uint256 c = a * b;
            if (c / a != b) return (false, 0);
            return (true, c);
        }
    }

    /**
     * @dev Returns the division of two unsigned integers, with a division by zero flag.
     *
     * _Available since v3.4._
     */
    function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b == 0) return (false, 0);
            return (true, a / b);
        }
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag.
     *
     * _Available since v3.4._
     */
    function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b == 0) return (false, 0);
            return (true, a % b);
        }
    }

    /**
     * @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) {
        return a + b;
    }

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

    /**
     * @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) {
        return a * b;
    }

    /**
     * @dev Returns the integer division of two unsigned integers, reverting on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator.
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b) internal pure returns (uint256) {
        return a / b;
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * reverting 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 a % b;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting with custom message on
     * overflow (when the result is negative).
     *
     * CAUTION: This function is deprecated because it requires allocating memory for the error
     * message unnecessarily. For custom revert reasons use {trySub}.
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(
        uint256 a,
        uint256 b,
        string memory errorMessage
    ) internal pure returns (uint256) {
        unchecked {
            require(b <= a, errorMessage);
            return a - b;
        }
    }

    /**
     * @dev Returns the integer division of two unsigned integers, reverting 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) {
        unchecked {
            require(b > 0, errorMessage);
            return a / b;
        }
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * reverting with custom message when dividing by zero.
     *
     * CAUTION: This function is deprecated because it requires allocating memory for the error
     * message unnecessarily. For custom revert reasons use {tryMod}.
     *
     * 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) {
        unchecked {
            require(b > 0, errorMessage);
            return a % b;
        }
    }
}

File 15 of 15 : DesperateApeWives.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.8.2;

/*

██████╗  █████╗ ██╗    ██╗
██╔══██╗██╔══██╗██║    ██║
██║  ██║███████║██║ █╗ ██║
██║  ██║██╔══██║██║███╗██║
██████╔╝██║  ██║╚███╔███╔╝
╚═════╝ ╚═╝  ╚═╝ ╚══╝╚══╝

*/

import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol";
import "@openzeppelin/contracts/finance/PaymentSplitter.sol";

contract DesperateApeWives is Ownable, ERC721Enumerable, PaymentSplitter {

    uint public constant MAX_WIVES = 10000;
    uint private DAW_PRICE = 0.08 ether;
    uint private walletLimit = 3;
    string public PROVENANCE_HASH;
    string private _baseURIExtended;
    string private _contractURI;
    bool public _isSaleLive = false;
    bool private locked;
    bool private PROVENANCE_LOCK = false;
    uint public _reserved;

    //Desperate Ape Wives Release Time -
    uint public presaleStart = 1635260400; // October 26th 11AM EST
    uint public presaleEnd = 1635303600;   // October 26th 11PM EST
    uint public publicSale = 1635350400;   // October 27th 12PM EST

    struct Account {
        uint nftsReserved;
        uint walletLimit;
        uint mintedNFTs;
        bool isEarlySupporter;
        bool isWhitelist;
        bool isAdmin;
    }

    mapping(address => Account) public accounts;

    event Mint(address indexed sender, uint totalSupply);
    event PermanentURI(string _value, uint256 indexed _id);

    address[] private _team;
    uint[] private _team_shares;

    address private donation;

    constructor(address[] memory team, uint[] memory team_shares, address[] memory admins, address d1)
        ERC721("Desperate ApeWives", "DAW")
        PaymentSplitter(team, team_shares)
    {
        _baseURIExtended = "ipfs://QmbmjFdnvbYzvD6QfQzLg75TT6Du3hw4rx5Kh1uuqMqevV/";

        accounts[msg.sender] = Account( 0, 0, 0, true, true, true);

        accounts[admins[0]] = Account( 12, 0, 0, false, false, true);
        accounts[admins[1]] = Account( 13, 0, 0, false, false, true);
        accounts[admins[2]] = Account( 12, 0, 0, false, false, true);
        accounts[admins[3]] = Account( 13, 0, 0, false, false, true);
        accounts[admins[4]] = Account( 16, 0, 0, false, false, true);
        accounts[admins[5]] = Account( 17, 0, 0, false, false, true);
        accounts[admins[6]] = Account( 17, 0, 0, false, false, true);
        accounts[admins[7]] = Account( 90, 0, 0, false, false, true);

        _reserved = 190;

        _team = team;
        _team_shares = team_shares;

        donation = d1;
    }

    // Modifiers

    modifier onlyAdmin() {
        require(accounts[msg.sender].isAdmin == true, "Nice try! You need to be an admin");
        _;
    }

    modifier noReentrant() {
        require(!locked, "No re-entrancy");
        locked = true;
        _;
        locked = false;
    }

    // End Modifier

    // Setters

    function setAdmin(address _addr) external onlyOwner {
        accounts[_addr].isAdmin = !accounts[_addr].isAdmin;
    }

    function setProvenanceHash(string memory _provenanceHash) external onlyOwner {
        require(PROVENANCE_LOCK == false);
        PROVENANCE_HASH = _provenanceHash;
    }

    function lockProvenance() external onlyOwner {
        PROVENANCE_LOCK = true;
    }

    function setBaseURI(string memory _newURI) external onlyAdmin {
        _baseURIExtended = _newURI;
    }

    function setContractURI(string memory _newURI) external onlyAdmin {
        _contractURI = _newURI;
    }

    function deactivateSale() external onlyOwner {
        _isSaleLive = false;
    }

    function activateSale() external onlyOwner {
        _isSaleLive = true;
    }

    function setEarlySupporters(address[] memory _addr) external onlyAdmin {
        for(uint i = 0; i < _addr.length; i++) {
            accounts[_addr[i]].walletLimit = 10;
            accounts[_addr[i]].isEarlySupporter = true;
        }
    }

    function setEarlySupporters5(address[] memory _addr) external onlyAdmin {
        for(uint i = 0; i < _addr.length; i++) {
            accounts[_addr[i]].walletLimit = 5;
            accounts[_addr[i]].isEarlySupporter = true;
        }
    }

    function setWhitelist(address[] memory _addr) external onlyAdmin {
        for(uint i = 0; i < _addr.length; i++) {
            accounts[_addr[i]].walletLimit = 2;
            accounts[_addr[i]].isWhitelist = true;
        }
    }

    function setSaleTimes(uint[] memory _newTimes) external onlyAdmin {
        require(_newTimes.length == 3, "You need to update all times at once");
        presaleStart = _newTimes[0];
        presaleEnd = _newTimes[1];
        publicSale = _newTimes[2];
    }

    // End Setter

    // Getters

    function getSaleTimes() public view returns (uint, uint, uint) {
        return (presaleStart, presaleEnd, publicSale);
    }

    // For OpenSea
    function contractURI() public view returns (string memory) {
        return _contractURI;
    }

    // For Metadata
    function _baseURI() internal view virtual override returns (string memory) {
        return _baseURIExtended;
    }

    // End Getter

    // Business Logic

    function claimDonations() external onlyAdmin {
        require(totalSupply() + 2 <= (MAX_WIVES - _reserved), "You would exceed the limit");

        _safeMint(donation, 1); // Good Dollar Donation
        _safeMint(donation, 2); // Brest Cancer Donation
        emit Mint(msg.sender, totalSupply());
    }

    function adminMint() external onlyAdmin {
        uint _amount = accounts[msg.sender].nftsReserved;
        require(accounts[msg.sender].isAdmin == true,"Nice Try! Only an admin can mint");
        require(_amount > 0, 'Need to have reserved supply');
        require(totalSupply() + _amount <= MAX_WIVES, "You would exceed the limit");

        accounts[msg.sender].nftsReserved -= _amount;
        _reserved = _reserved - _amount;

        uint id = totalSupply();

        for (uint i = 0; i < _amount; i++) {
            id++;
            _safeMint(msg.sender, id);
            emit Mint(msg.sender, totalSupply());
        }
    }

    function airDropMany(address[] memory _addr) external onlyAdmin {
        require(totalSupply() + _addr.length <= (MAX_WIVES - _reserved), "You would exceed the limit");

        // DO MINT
        uint id = totalSupply();

        for (uint i = 0; i < _addr.length; i++) {
            id++;
            _safeMint(_addr[i], id);
            emit Mint(msg.sender, totalSupply());
        }

    }

    function mintWife(uint _amount) external payable noReentrant {
        // CHECK BASIC SALE CONDITIONS
        require(_isSaleLive, "Sale must be active to mint");
        require(block.timestamp >= presaleStart, "You must wait till presale begins to mint");
        require(_amount > 0, "Must mint at least one token and under 10");
        require(totalSupply() + _amount <= (MAX_WIVES - _reserved), "Purchase would exceed max supply of Apes");
        require(msg.value >= (DAW_PRICE * _amount), "Ether value sent is not correct");
        require(!isContract(msg.sender), "Contracts can't mint");

        if(block.timestamp >= publicSale) {
            require((_amount + accounts[msg.sender].mintedNFTs) <= walletLimit, "Sorry you can only mint 3 per wallet");
        } else if(block.timestamp >= presaleEnd) {
            require(false, "Presale has Ended please Wait till Public sale");
        } else if(block.timestamp >= presaleStart) {
            require(accounts[msg.sender].isWhitelist || accounts[msg.sender].isEarlySupporter, "Sorry you need to be on Whitelist");
            require((_amount + accounts[msg.sender].mintedNFTs) <= accounts[msg.sender].walletLimit, "Wallet Limit Reached");
        }

        // DO MINT
        uint id = totalSupply();

        for (uint i = 0; i < _amount; i++) {
            id++;
            accounts[msg.sender].mintedNFTs++;
            _safeMint(msg.sender, id);
            emit Mint(msg.sender, totalSupply());
        }

    }

    function releaseFunds() external onlyAdmin {
        for (uint i = 0; i < _team.length; i++) {
            release(payable(_team[i]));
        }
    }

    // helper

    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize, which returns 0 for contracts in
        // construction, since the code is only stored at the end of the
        // constructor execution.

        uint256 size;

        assembly {
            size := extcodesize(account)
        }

        return size > 0;
    }

}

Settings
{
  "evmVersion": "istanbul",
  "libraries": {},
  "metadata": {
    "bytecodeHash": "ipfs",
    "useLiteralContent": true
  },
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "remappings": [],
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  }
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address[]","name":"team","type":"address[]"},{"internalType":"uint256[]","name":"team_shares","type":"uint256[]"},{"internalType":"address[]","name":"admins","type":"address[]"},{"internalType":"address","name":"d1","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"uint256","name":"totalSupply","type":"uint256"}],"name":"Mint","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"shares","type":"uint256"}],"name":"PayeeAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"PaymentReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"PaymentReleased","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"_value","type":"string"},{"indexed":true,"internalType":"uint256","name":"_id","type":"uint256"}],"name":"PermanentURI","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"MAX_WIVES","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"PROVENANCE_HASH","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_isSaleLive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_reserved","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"accounts","outputs":[{"internalType":"uint256","name":"nftsReserved","type":"uint256"},{"internalType":"uint256","name":"walletLimit","type":"uint256"},{"internalType":"uint256","name":"mintedNFTs","type":"uint256"},{"internalType":"bool","name":"isEarlySupporter","type":"bool"},{"internalType":"bool","name":"isWhitelist","type":"bool"},{"internalType":"bool","name":"isAdmin","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"activateSale","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"adminMint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_addr","type":"address[]"}],"name":"airDropMany","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"claimDonations","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"contractURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"deactivateSale","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getSaleTimes","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"lockProvenance","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"mintWife","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"payee","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"presaleEnd","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"presaleStart","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"publicSale","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address payable","name":"account","type":"address"}],"name":"release","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"releaseFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"released","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_addr","type":"address"}],"name":"setAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_newURI","type":"string"}],"name":"setBaseURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_newURI","type":"string"}],"name":"setContractURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_addr","type":"address[]"}],"name":"setEarlySupporters","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_addr","type":"address[]"}],"name":"setEarlySupporters5","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_provenanceHash","type":"string"}],"name":"setProvenanceHash","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_newTimes","type":"uint256[]"}],"name":"setSaleTimes","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_addr","type":"address[]"}],"name":"setWhitelist","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"shares","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenOfOwnerByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalReleased","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalShares","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}]

608060405267011c37937e08000060105560036011556015805462ff00ff1916905563617817f0601755636178c0b060185563617977806019553480156200004657600080fd5b506040516200480e3803806200480e833981016040819052620000699162000e73565b83836040518060400160405280601281526020017144657370657261746520417065576976657360701b8152506040518060400160405280600381526020016244415760e81b815250620000cc620000c662000a5c60201b60201c565b62000a60565b8151620000e190600190602085019062000c9e565b508051620000f790600290602084019062000c9e565b50505080518251146200016c5760405162461bcd60e51b815260206004820152603260248201527f5061796d656e7453706c69747465723a2070617965657320616e6420736861726044820152710cae640d8cadccee8d040dad2e6dac2e8c6d60731b60648201526084015b60405180910390fd5b6000825111620001bf5760405162461bcd60e51b815260206004820152601a60248201527f5061796d656e7453706c69747465723a206e6f20706179656573000000000000604482015260640162000163565b60005b825181101562000243576200022e838281518110620001f157634e487b7160e01b600052603260045260246000fd5b60200260200101518383815181106200021a57634e487b7160e01b600052603260045260246000fd5b602002602001015162000ab060201b60201c565b806200023a816200101f565b915050620001c2565b505050604051806060016040528060368152602001620047d8603691398051620002769160139160209091019062000c9e565b506040805160c0808201835260008083526020808401828152848601838152600160608088018281526080808a0184815260a0808c01868152338b52601a808b528e8c209d518e5598518d880155965160028d015592516003909b018054915196511515620100000262ff0000199715156101000261ff00199d151560ff19909416939093179c909c1691909117959095169990991790935588519687018952600c87529386018590529685018490529184018390529383018290528201939093528451909290859082906200035c57634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208451815584840151600180830191909155858401516002830155606080870151600390930180546080808a015160a09a8b015160ff199093169615159690961761ff001916610100961515969096029590951762ff000019166201000091151591909102179055845160c081018652600d8152958601849052938501839052928401829052830181905292820181905284519192601a929091869181106200043c57634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b031682528181019290925260409081016000908120845181558484015160018083019190915585840151600280840191909155606080880151600390940180546080808b015160a09b8c015160ff199093169715159790971761ff001916610100971515979097029690961762ff000019166201000091151591909102179055855160c081018752600c81529687018590529486018490529385018390529084018290529383019390935284519192601a929091869181106200052257634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208451815584840151600180830191909155858401516002830155606080870151600393840180546080808b015160a09b8c015160ff199093169415159490941761ff001916610100941515949094029390931762ff000019166201000091151591909102179055855160c081018752600d815296870185905294860184905285018390529284018290529383019190915284519192601a9286919081106200060257634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208451815584840151600180830191909155858401516002830155606080870151600390930180546080808a015160a09a8b015160ff199093169615159690961761ff001916610100961515969096029590951762ff000019166201000091151591909102179055845160c0810186526010815295860184905293850183905292840182905283018190529282015283519091601a9185906004908110620006e157634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208451815584840151600180830191909155858401516002830155606080870151600390930180546080808a015160a09a8b015160ff199093169615159690961761ff001916610100961515969096029590951762ff000019166201000091151591909102179055845160c0810186526011815295860184905293850183905292840182905283018190529282015283519091601a9185906005908110620007c057634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208451815584840151600180830191909155858401516002830155606080870151600390930180546080808a015160a09a8b015160ff199093169615159690961761ff001916610100961515969096029590951762ff000019166201000091151591909102179055845160c0810186526011815295860184905293850183905292840182905283018190529282015283519091601a91859060069081106200089f57634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208451815584840151600180830191909155858401516002830155606080870151600390930180546080808a015160a09a8b015160ff199093169615159690961761ff001916610100961515969096029590951762ff000019166201000091151591909102179055845160c081018652605a815295860184905293850183905292840182905283018190529282015283519091601a91859060079081106200097e57634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b0316825281810192909252604090810160002083518155838301516001820155908301516002820155606083015160039091018054608085015160a0909501511515620100000262ff0000199515156101000261ff001994151560ff19909316929092179390931617939093161790915560be601655845162000a1b91601b919087019062000d2d565b50825162000a3190601c90602086019062000d85565b50601d80546001600160a01b0319166001600160a01b03929092169190911790555062001069915050565b3390565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6001600160a01b03821662000b1d5760405162461bcd60e51b815260206004820152602c60248201527f5061796d656e7453706c69747465723a206163636f756e74206973207468652060448201526b7a65726f206164647265737360a01b606482015260840162000163565b6000811162000b6f5760405162461bcd60e51b815260206004820152601d60248201527f5061796d656e7453706c69747465723a20736861726573206172652030000000604482015260640162000163565b6001600160a01b0382166000908152600d60205260409020541562000beb5760405162461bcd60e51b815260206004820152602b60248201527f5061796d656e7453706c69747465723a206163636f756e7420616c726561647960448201526a206861732073686172657360a81b606482015260840162000163565b600f8054600181019091557f8d1108e10bcb7c27dddfc02ed9d693a074039d026cf4ea4240b40f7d581ac8020180546001600160a01b0319166001600160a01b0384169081179091556000908152600d60205260409020819055600b5462000c5590829062000fc7565b600b55604080516001600160a01b0384168152602081018390527f40c340f65e17194d14ddddb073d3c9f888e3cb52b5aae0c6c7706b4fbc905fac910160405180910390a15050565b82805462000cac9062000fe2565b90600052602060002090601f01602090048101928262000cd0576000855562000d1b565b82601f1062000ceb57805160ff191683800117855562000d1b565b8280016001018555821562000d1b579182015b8281111562000d1b57825182559160200191906001019062000cfe565b5062000d2992915062000dc2565b5090565b82805482825590600052602060002090810192821562000d1b579160200282015b8281111562000d1b57825182546001600160a01b0319166001600160a01b0390911617825560209092019160019091019062000d4e565b82805482825590600052602060002090810192821562000d1b579160200282018281111562000d1b57825182559160200191906001019062000cfe565b5b8082111562000d29576000815560010162000dc3565b80516001600160a01b038116811462000df157600080fd5b919050565b600082601f83011262000e07578081fd5b8151602062000e2062000e1a8362000fa1565b62000f6e565b828152818101908583018385028701840188101562000e3d578586fd5b855b8581101562000e665762000e538262000dd9565b8452928401929084019060010162000e3f565b5090979650505050505050565b6000806000806080858703121562000e89578384fd5b84516001600160401b038082111562000ea0578586fd5b62000eae8883890162000df6565b955060209150818701518181111562000ec5578586fd5b8701601f8101891362000ed6578586fd5b805162000ee762000e1a8262000fa1565b81815284810190838601868402850187018d101562000f0457898afd5b8994505b8385101562000f2857805183526001949094019391860191860162000f08565b5060408b015190985094505050508082111562000f43578384fd5b5062000f528782880162000df6565b92505062000f636060860162000dd9565b905092959194509250565b604051601f8201601f191681016001600160401b038111828210171562000f995762000f9962001053565b604052919050565b60006001600160401b0382111562000fbd5762000fbd62001053565b5060209081020190565b6000821982111562000fdd5762000fdd6200103d565b500190565b60028104600182168062000ff757607f821691505b602082108114156200101957634e487b7160e01b600052602260045260246000fd5b50919050565b60006000198214156200103657620010366200103d565b5060010190565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052604160045260246000fd5b61375f80620010796000396000f3fe6080604052600436106102e85760003560e01c80636aaa571d11610190578063c87b56dd116100dc578063e985e9c511610095578063eceecdad1161006f578063eceecdad14610964578063f2fde38b14610977578063f421764814610997578063ff1b6556146109b757610331565b8063e985e9c5146108e6578063ea7523ee1461092f578063ecad582a1461094457610331565b8063c87b56dd14610830578063cadf7c4d14610850578063ce7c2ac214610870578063de8801e5146108a6578063e33b7de3146108bc578063e8a3d485146108d157610331565b80638da5cb5b116101495780639852595c116101235780639852595c146107a5578063a22cb465146107db578063b88d4fde146107fb578063c721f08d1461081b57610331565b80638da5cb5b14610752578063938e3d7b1461077057806395d89b411461079057610331565b80636aaa571d146106b2578063704b6c02146106c857806370a08231146106e8578063715018a614610708578063895fc7881461071d5780638b83209b1461073257610331565b8063385b7b311161024f5780634f6ccce7116102085780635e5c06e2116101e25780635e5c06e2146105dd578063616d0dfd146106685780636352211e1461067d57806369d895751461069d57610331565b80634f6ccce71461056c57806355f804b31461058c57806358d21178146105ac57610331565b8063385b7b31146104d25780633a98ef39146104e85780633e78b91c146104fd57806342842e0e1461051d578063464968e61461053d5780634f5e0b281461055257610331565b806319165587116102a15780631916558714610426578063229f3e291461044657806323b872dd1461045c5780632f745c591461047c578063320f62981461049c57806333bc1c5c146104bc57610331565b806301ffc9a71461033657806306fdde031461036b578063081812fc1461038d578063095ea7b3146103c557806310969523146103e757806318160ddd1461040757610331565b36610331577f6ef95f06320e7a25a04a175ca677b7052bdd97131872c2192525a629f51be77033604080516001600160a01b0390921682523460208301520160405180910390a1005b600080fd5b34801561034257600080fd5b506103566103513660046132be565b6109cc565b60405190151581526020015b60405180910390f35b34801561037757600080fd5b506103806109f9565b60405161036291906133ec565b34801561039957600080fd5b506103ad6103a836600461333c565b610a8b565b6040516001600160a01b039091168152602001610362565b3480156103d157600080fd5b506103e56103e0366004613171565b610b25565b005b3480156103f357600080fd5b506103e56104023660046132f6565b610c3b565b34801561041357600080fd5b506009545b604051908152602001610362565b34801561043257600080fd5b506103e561044136600461302f565b610c92565b34801561045257600080fd5b5061041860185481565b34801561046857600080fd5b506103e5610477366004613083565b610e63565b34801561048857600080fd5b50610418610497366004613171565b610e94565b3480156104a857600080fd5b506103e56104b736600461319c565b610f2a565b3480156104c857600080fd5b5061041860195481565b3480156104de57600080fd5b5061041861271081565b3480156104f457600080fd5b50600b54610418565b34801561050957600080fd5b506103e561051836600461319c565b611035565b34801561052957600080fd5b506103e5610538366004613083565b611140565b34801561054957600080fd5b506103e561115b565b34801561055e57600080fd5b506015546103569060ff1681565b34801561057857600080fd5b5061041861058736600461333c565b61122d565b34801561059857600080fd5b506103e56105a73660046132f6565b6112ce565b3480156105b857600080fd5b5060175460185460195460408051938452602084019290925290820152606001610362565b3480156105e957600080fd5b506106356105f836600461302f565b601a6020526000908152604090208054600182015460028301546003909301549192909160ff808216916101008104821691620100009091041686565b604080519687526020870195909552938501929092521515606084015215156080830152151560a082015260c001610362565b34801561067457600080fd5b506103e561131e565b34801561068957600080fd5b506103ad61069836600461333c565b611354565b3480156106a957600080fd5b506103e56113cb565b3480156106be57600080fd5b5061041860165481565b3480156106d457600080fd5b506103e56106e336600461302f565b611468565b3480156106f457600080fd5b5061041861070336600461302f565b6114c9565b34801561071457600080fd5b506103e5611550565b34801561072957600080fd5b506103e5611586565b34801561073e57600080fd5b506103ad61074d36600461333c565b611759565b34801561075e57600080fd5b506000546001600160a01b03166103ad565b34801561077c57600080fd5b506103e561078b3660046132f6565b611797565b34801561079c57600080fd5b506103806117e7565b3480156107b157600080fd5b506104186107c036600461302f565b6001600160a01b03166000908152600e602052604090205490565b3480156107e757600080fd5b506103e56107f6366004613140565b6117f6565b34801561080757600080fd5b506103e56108163660046130c3565b6118c8565b34801561082757600080fd5b506103e5611900565b34801561083c57600080fd5b5061038061084b36600461333c565b611939565b34801561085c57600080fd5b506103e561086b36600461319c565b611a14565b34801561087c57600080fd5b5061041861088b36600461302f565b6001600160a01b03166000908152600d602052604090205490565b3480156108b257600080fd5b5061041860175481565b3480156108c857600080fd5b50600c54610418565b3480156108dd57600080fd5b50610380611b20565b3480156108f257600080fd5b5061035661090136600461304b565b6001600160a01b03918216600090815260066020908152604080832093909416825291909152205460ff1690565b34801561093b57600080fd5b506103e5611b2f565b34801561095057600080fd5b506103e561095f36600461323a565b611b6c565b6103e561097236600461333c565b611c96565b34801561098357600080fd5b506103e561099236600461302f565b6121ba565b3480156109a357600080fd5b506103e56109b236600461319c565b612252565b3480156109c357600080fd5b5061038061236b565b60006001600160e01b0319821663780e9d6360e01b14806109f157506109f1826123f9565b90505b919050565b606060018054610a0890613632565b80601f0160208091040260200160405190810160405280929190818152602001828054610a3490613632565b8015610a815780601f10610a5657610100808354040283529160200191610a81565b820191906000526020600020905b815481529060010190602001808311610a6457829003601f168201915b5050505050905090565b6000818152600360205260408120546001600160a01b0316610b095760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084015b60405180910390fd5b506000908152600560205260409020546001600160a01b031690565b6000610b3082611354565b9050806001600160a01b0316836001600160a01b03161415610b9e5760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610b00565b336001600160a01b0382161480610bba5750610bba8133610901565b610c2c5760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610b00565b610c368383612449565b505050565b6000546001600160a01b03163314610c655760405162461bcd60e51b8152600401610b0090613451565b60155462010000900460ff1615610c7b57600080fd5b8051610c8e906012906020840190612f3e565b5050565b6001600160a01b0381166000908152600d6020526040902054610d065760405162461bcd60e51b815260206004820152602660248201527f5061796d656e7453706c69747465723a206163636f756e7420686173206e6f2060448201526573686172657360d01b6064820152608401610b00565b6000600c5447610d1691906135a4565b6001600160a01b0383166000908152600e6020908152604080832054600b54600d909352908320549394509192610d4d90856135d0565b610d5791906135bc565b610d6191906135ef565b905080610dc45760405162461bcd60e51b815260206004820152602b60248201527f5061796d656e7453706c69747465723a206163636f756e74206973206e6f742060448201526a191d59481c185e5b595b9d60aa1b6064820152608401610b00565b6001600160a01b0383166000908152600e6020526040902054610de89082906135a4565b6001600160a01b0384166000908152600e6020526040902055600c54610e0f9082906135a4565b600c55610e1c83826124b7565b604080516001600160a01b0385168152602081018390527fdf20fd1e76bc69d672e4814fafb2c449bba3a5369d8359adf9e05e6fde87b056910160405180910390a1505050565b610e6d33826125d0565b610e895760405162461bcd60e51b8152600401610b00906134fe565b610c368383836126c7565b6000610e9f836114c9565b8210610f015760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201526a74206f6620626f756e647360a81b6064820152608401610b00565b506001600160a01b03919091166000908152600760209081526040808320938352929052205490565b336000908152601a602052604090206003015462010000900460ff161515600114610f675760405162461bcd60e51b8152600401610b00906134bd565b60005b8151811015610c8e57600a601a6000848481518110610f9957634e487b7160e01b600052603260045260246000fd5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600101819055506001601a6000848481518110610fee57634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b03168252810191909152604001600020600301805460ff19169115159190911790558061102d8161366d565b915050610f6a565b336000908152601a602052604090206003015462010000900460ff1615156001146110725760405162461bcd60e51b8152600401610b00906134bd565b60005b8151811015610c8e576005601a60008484815181106110a457634e487b7160e01b600052603260045260246000fd5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600101819055506001601a60008484815181106110f957634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b03168252810191909152604001600020600301805460ff1916911515919091179055806111388161366d565b915050611075565b610c36838383604051806020016040528060008152506118c8565b336000908152601a602052604090206003015462010000900460ff1615156001146111985760405162461bcd60e51b8152600401610b00906134bd565b6016546111a7906127106135ef565b6009546111b59060026135a4565b11156111d35760405162461bcd60e51b8152600401610b0090613486565b601d546111ea906001600160a01b03166001612872565b601d54611201906001600160a01b03166002612872565b3360008051602061370a83398151915261121a60095490565b60405190815260200160405180910390a2565b600061123860095490565b821061129b5760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201526b7574206f6620626f756e647360a01b6064820152608401610b00565b600982815481106112bc57634e487b7160e01b600052603260045260246000fd5b90600052602060002001549050919050565b336000908152601a602052604090206003015462010000900460ff16151560011461130b5760405162461bcd60e51b8152600401610b00906134bd565b8051610c8e906013906020840190612f3e565b6000546001600160a01b031633146113485760405162461bcd60e51b8152600401610b0090613451565b6015805460ff19169055565b6000818152600360205260408120546001600160a01b0316806109f15760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610b00565b336000908152601a602052604090206003015462010000900460ff1615156001146114085760405162461bcd60e51b8152600401610b00906134bd565b60005b601b5481101561146557611453601b828154811061143957634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546001600160a01b0316610c92565b8061145d8161366d565b91505061140b565b50565b6000546001600160a01b031633146114925760405162461bcd60e51b8152600401610b0090613451565b6001600160a01b03166000908152601a60205260409020600301805462ff0000198116620100009182900460ff1615909102179055565b60006001600160a01b0382166115345760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610b00565b506001600160a01b031660009081526004602052604090205490565b6000546001600160a01b0316331461157a5760405162461bcd60e51b8152600401610b0090613451565b611584600061288c565b565b336000908152601a602052604090206003015462010000900460ff1615156001146115c35760405162461bcd60e51b8152600401610b00906134bd565b336000908152601a60205260409020805460039091015462010000900460ff1615156001146116345760405162461bcd60e51b815260206004820181905260248201527f4e6963652054727921204f6e6c7920616e2061646d696e2063616e206d696e746044820152606401610b00565b600081116116845760405162461bcd60e51b815260206004820152601c60248201527f4e65656420746f206861766520726573657276656420737570706c79000000006044820152606401610b00565b6127108161169160095490565b61169b91906135a4565b11156116b95760405162461bcd60e51b8152600401610b0090613486565b336000908152601a6020526040812080548392906116d89084906135ef565b90915550506016546116eb9082906135ef565b60165560006116f960095490565b905060005b82811015610c3657816117108161366d565b92505061171d3383612872565b3360008051602061370a83398151915261173660095490565b60405190815260200160405180910390a2806117518161366d565b9150506116fe565b6000600f828154811061177c57634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546001600160a01b031692915050565b336000908152601a602052604090206003015462010000900460ff1615156001146117d45760405162461bcd60e51b8152600401610b00906134bd565b8051610c8e906014906020840190612f3e565b606060028054610a0890613632565b6001600160a01b03821633141561184f5760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610b00565b3360008181526006602090815260408083206001600160a01b0387168085529252909120805460ff1916841515179055906001600160a01b03167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31836040516118bc911515815260200190565b60405180910390a35050565b6118d233836125d0565b6118ee5760405162461bcd60e51b8152600401610b00906134fe565b6118fa848484846128dc565b50505050565b6000546001600160a01b0316331461192a5760405162461bcd60e51b8152600401610b0090613451565b6015805460ff19166001179055565b6000818152600360205260409020546060906001600160a01b03166119b85760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b6064820152608401610b00565b60006119c261290f565b905060008151116119e25760405180602001604052806000815250611a0d565b806119ec8461291e565b6040516020016119fd929190613380565b6040516020818303038152906040525b9392505050565b336000908152601a602052604090206003015462010000900460ff161515600114611a515760405162461bcd60e51b8152600401610b00906134bd565b601654611a60906127106135ef565b8151600954611a6f91906135a4565b1115611a8d5760405162461bcd60e51b8152600401610b0090613486565b6000611a9860095490565b905060005b8251811015610c365781611ab08161366d565b925050611ae4838281518110611ad657634e487b7160e01b600052603260045260246000fd5b602002602001015183612872565b3360008051602061370a833981519152611afd60095490565b60405190815260200160405180910390a280611b188161366d565b915050611a9d565b606060148054610a0890613632565b6000546001600160a01b03163314611b595760405162461bcd60e51b8152600401610b0090613451565b6015805462ff0000191662010000179055565b336000908152601a602052604090206003015462010000900460ff161515600114611ba95760405162461bcd60e51b8152600401610b00906134bd565b8051600314611c065760405162461bcd60e51b8152602060048201526024808201527f596f75206e65656420746f2075706461746520616c6c2074696d6573206174206044820152636f6e636560e01b6064820152608401610b00565b80600081518110611c2757634e487b7160e01b600052603260045260246000fd5b602002602001015160178190555080600181518110611c5657634e487b7160e01b600052603260045260246000fd5b602002602001015160188190555080600281518110611c8557634e487b7160e01b600052603260045260246000fd5b602002602001015160198190555050565b601554610100900460ff1615611cdf5760405162461bcd60e51b815260206004820152600e60248201526d4e6f2072652d656e7472616e637960901b6044820152606401610b00565b6015805461ff001916610100179081905560ff16611d3f5760405162461bcd60e51b815260206004820152601b60248201527f53616c65206d7573742062652061637469766520746f206d696e7400000000006044820152606401610b00565b601754421015611da35760405162461bcd60e51b815260206004820152602960248201527f596f75206d75737420776169742074696c6c2070726573616c6520626567696e6044820152681cc81d1bc81b5a5b9d60ba1b6064820152608401610b00565b60008111611e055760405162461bcd60e51b815260206004820152602960248201527f4d757374206d696e74206174206c65617374206f6e6520746f6b656e20616e64604482015268020756e6465722031360bc1b6064820152608401610b00565b601654611e14906127106135ef565b81611e1e60095490565b611e2891906135a4565b1115611e875760405162461bcd60e51b815260206004820152602860248201527f507572636861736520776f756c6420657863656564206d617820737570706c79604482015267206f66204170657360c01b6064820152608401610b00565b80601054611e9591906135d0565b341015611ee45760405162461bcd60e51b815260206004820152601f60248201527f45746865722076616c75652073656e74206973206e6f7420636f7272656374006044820152606401610b00565b333b15611f2a5760405162461bcd60e51b815260206004820152601460248201527310dbdb9d1c9858dd1cc818d85b89dd081b5a5b9d60621b6044820152606401610b00565b6019544210611fb257601154336000908152601a6020526040902060020154611f5390836135a4565b1115611fad5760405162461bcd60e51b8152602060048201526024808201527f536f72727920796f752063616e206f6e6c79206d696e742033207065722077616044820152631b1b195d60e21b6064820152608401610b00565b61211a565b601854421061201a5760405162461bcd60e51b815260206004820152602e60248201527f50726573616c652068617320456e64656420706c65617365205761697420746960448201526d6c6c205075626c69632073616c6560901b6064820152608401610b00565b601754421061211a57336000908152601a6020526040902060030154610100900460ff168061205b5750336000908152601a602052604090206003015460ff165b6120b15760405162461bcd60e51b815260206004820152602160248201527f536f72727920796f75206e65656420746f206265206f6e2057686974656c69736044820152601d60fa1b6064820152608401610b00565b336000908152601a6020526040902060018101546002909101546120d590836135a4565b111561211a5760405162461bcd60e51b815260206004820152601460248201527315d85b1b195d08131a5b5a5d0814995858da195960621b6044820152606401610b00565b600061212560095490565b905060005b828110156121aa578161213c8161366d565b336000908152601a60205260408120600201805492955091925061215f8361366d565b919050555061216e3383612872565b3360008051602061370a83398151915261218760095490565b60405190815260200160405180910390a2806121a28161366d565b91505061212a565b50506015805461ff001916905550565b6000546001600160a01b031633146121e45760405162461bcd60e51b8152600401610b0090613451565b6001600160a01b0381166122495760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610b00565b6114658161288c565b336000908152601a602052604090206003015462010000900460ff16151560011461228f5760405162461bcd60e51b8152600401610b00906134bd565b60005b8151811015610c8e576002601a60008484815181106122c157634e487b7160e01b600052603260045260246000fd5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600101819055506001601a600084848151811061231657634e487b7160e01b600052603260045260246000fd5b60200260200101516001600160a01b03166001600160a01b0316815260200190815260200160002060030160016101000a81548160ff02191690831515021790555080806123639061366d565b915050612292565b6012805461237890613632565b80601f01602080910402602001604051908101604052809291908181526020018280546123a490613632565b80156123f15780601f106123c6576101008083540402835291602001916123f1565b820191906000526020600020905b8154815290600101906020018083116123d457829003601f168201915b505050505081565b60006001600160e01b031982166380ac58cd60e01b148061242a57506001600160e01b03198216635b5e139f60e01b145b806109f157506301ffc9a760e01b6001600160e01b03198316146109f1565b600081815260056020526040902080546001600160a01b0319166001600160a01b038416908117909155819061247e82611354565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b804710156125075760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e63650000006044820152606401610b00565b6000826001600160a01b03168260405160006040518083038185875af1925050503d8060008114612554576040519150601f19603f3d011682016040523d82523d6000602084013e612559565b606091505b5050905080610c365760405162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152608401610b00565b6000818152600360205260408120546001600160a01b03166126495760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610b00565b600061265483611354565b9050806001600160a01b0316846001600160a01b0316148061268f5750836001600160a01b031661268484610a8b565b6001600160a01b0316145b806126bf57506001600160a01b0380821660009081526006602090815260408083209388168352929052205460ff165b949350505050565b826001600160a01b03166126da82611354565b6001600160a01b0316146127425760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b6064820152608401610b00565b6001600160a01b0382166127a45760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610b00565b6127af838383612a39565b6127ba600082612449565b6001600160a01b03831660009081526004602052604081208054600192906127e39084906135ef565b90915550506001600160a01b03821660009081526004602052604081208054600192906128119084906135a4565b909155505060008181526003602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b610c8e828260405180602001604052806000815250612af6565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6128e78484846126c7565b6128f384848484612b29565b6118fa5760405162461bcd60e51b8152600401610b00906133ff565b606060138054610a0890613632565b60608161294357506040805180820190915260018152600360fc1b60208201526109f4565b8160005b811561296d57806129578161366d565b91506129669050600a836135bc565b9150612947565b60008167ffffffffffffffff81111561299657634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f1916602001820160405280156129c0576020820181803683370190505b5090505b84156126bf576129d56001836135ef565b91506129e2600a86613688565b6129ed9060306135a4565b60f81b818381518110612a1057634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a905350612a32600a866135bc565b94506129c4565b6001600160a01b038316612a9457612a8f81600980546000838152600a60205260408120829055600182018355919091527f6e1540171b6c0c960b71a7020d9f60077f6af931a8bbf590da0223dacf75c7af0155565b612ab7565b816001600160a01b0316836001600160a01b031614612ab757612ab78382612c36565b6001600160a01b038216612ad357612ace81612cd3565b610c36565b826001600160a01b0316826001600160a01b031614610c3657610c368282612dac565b612b008383612df0565b612b0d6000848484612b29565b610c365760405162461bcd60e51b8152600401610b00906133ff565b60006001600160a01b0384163b15612c2b57604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290612b6d9033908990889088906004016133af565b602060405180830381600087803b158015612b8757600080fd5b505af1925050508015612bb7575060408051601f3d908101601f19168201909252612bb4918101906132da565b60015b612c11573d808015612be5576040519150601f19603f3d011682016040523d82523d6000602084013e612bea565b606091505b508051612c095760405162461bcd60e51b8152600401610b00906133ff565b805181602001fd5b6001600160e01b031916630a85bd0160e11b1490506126bf565b506001949350505050565b60006001612c43846114c9565b612c4d91906135ef565b600083815260086020526040902054909150808214612ca0576001600160a01b03841660009081526007602090815260408083208584528252808320548484528184208190558352600890915290208190555b5060009182526008602090815260408084208490556001600160a01b039094168352600781528383209183525290812055565b600954600090612ce5906001906135ef565b6000838152600a602052604081205460098054939450909284908110612d1b57634e487b7160e01b600052603260045260246000fd5b906000526020600020015490508060098381548110612d4a57634e487b7160e01b600052603260045260246000fd5b6000918252602080832090910192909255828152600a90915260408082208490558582528120556009805480612d9057634e487b7160e01b600052603160045260246000fd5b6001900381819060005260206000200160009055905550505050565b6000612db7836114c9565b6001600160a01b039093166000908152600760209081526040808320868452825280832085905593825260089052919091209190915550565b6001600160a01b038216612e465760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610b00565b6000818152600360205260409020546001600160a01b031615612eab5760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610b00565b612eb760008383612a39565b6001600160a01b0382166000908152600460205260408120805460019290612ee09084906135a4565b909155505060008181526003602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b828054612f4a90613632565b90600052602060002090601f016020900481019282612f6c5760008555612fb2565b82601f10612f8557805160ff1916838001178555612fb2565b82800160010185558215612fb2579182015b82811115612fb2578251825591602001919060010190612f97565b50612fbe929150612fc2565b5090565b5b80821115612fbe5760008155600101612fc3565b600067ffffffffffffffff831115612ff157612ff16136c8565b613004601f8401601f191660200161354f565b905082815283838301111561301857600080fd5b828260208301376000602084830101529392505050565b600060208284031215613040578081fd5b8135611a0d816136de565b6000806040838503121561305d578081fd5b8235613068816136de565b91506020830135613078816136de565b809150509250929050565b600080600060608486031215613097578081fd5b83356130a2816136de565b925060208401356130b2816136de565b929592945050506040919091013590565b600080600080608085870312156130d8578081fd5b84356130e3816136de565b935060208501356130f3816136de565b925060408501359150606085013567ffffffffffffffff811115613115578182fd5b8501601f81018713613125578182fd5b61313487823560208401612fd7565b91505092959194509250565b60008060408385031215613152578182fd5b823561315d816136de565b915060208301358015158114613078578182fd5b60008060408385031215613183578182fd5b823561318e816136de565b946020939093013593505050565b600060208083850312156131ae578182fd5b823567ffffffffffffffff8111156131c4578283fd5b8301601f810185136131d4578283fd5b80356131e76131e282613580565b61354f565b8181528381019083850185840285018601891015613203578687fd5b8694505b8385101561322e57803561321a816136de565b835260019490940193918501918501613207565b50979650505050505050565b6000602080838503121561324c578182fd5b823567ffffffffffffffff811115613262578283fd5b8301601f81018513613272578283fd5b80356132806131e282613580565b818152838101908385018584028501860189101561329c578687fd5b8694505b8385101561322e5780358352600194909401939185019185016132a0565b6000602082840312156132cf578081fd5b8135611a0d816136f3565b6000602082840312156132eb578081fd5b8151611a0d816136f3565b600060208284031215613307578081fd5b813567ffffffffffffffff81111561331d578182fd5b8201601f8101841361332d578182fd5b6126bf84823560208401612fd7565b60006020828403121561334d578081fd5b5035919050565b6000815180845261336c816020860160208601613606565b601f01601f19169290920160200192915050565b60008351613392818460208801613606565b8351908301906133a6818360208801613606565b01949350505050565b6001600160a01b03858116825284166020820152604081018390526080606082018190526000906133e290830184613354565b9695505050505050565b600060208252611a0d6020830184613354565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b6020808252601a908201527f596f7520776f756c642065786365656420746865206c696d6974000000000000604082015260600190565b60208082526021908201527f4e696365207472792120596f75206e65656420746f20626520616e2061646d696040820152603760f91b606082015260800190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b604051601f8201601f1916810167ffffffffffffffff81118282101715613578576135786136c8565b604052919050565b600067ffffffffffffffff82111561359a5761359a6136c8565b5060209081020190565b600082198211156135b7576135b761369c565b500190565b6000826135cb576135cb6136b2565b500490565b60008160001904831182151516156135ea576135ea61369c565b500290565b6000828210156136015761360161369c565b500390565b60005b83811015613621578181015183820152602001613609565b838111156118fa5750506000910152565b60028104600182168061364657607f821691505b6020821081141561366757634e487b7160e01b600052602260045260246000fd5b50919050565b60006000198214156136815761368161369c565b5060010190565b600082613697576136976136b2565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b038116811461146557600080fd5b6001600160e01b03198116811461146557600080fdfe0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d4121396885a2646970667358221220153eb3788e0a6eb07355e2bb42dcf46cb237ba385911dab5b3a7d15bc93838bc64736f6c63430008020033697066733a2f2f516d626d6a46646e7662597a7644365166517a4c6737355454364475336877347278354b68317575714d716576562f00000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000020000000000000000000000000047ef4eb0d047daf2fa7152c5f9ba8fc4ea5a957f0000000000000000000000000000000000000000000000000000000000000005000000000000000000000000b80ed04daf88401f20752bb40490b82f73de8687000000000000000000000000c43b7017871c611a23366584c487dc3aaf3c09ec000000000000000000000000ad8259e83b4a48a97360edcb808a2d2bf3ace1910000000000000000000000005f7aac1728f23cb06ba806741f0fff373eb581ba00000000000000000000000067aaef4a6f49a27cf90789ead73ba1d189b050d300000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000fa00000000000000000000000000000000000000000000000000000000000000fa0000000000000000000000000000000000000000000000000000000000000029b000000000000000000000000000000000000000000000000000000000000029b000000000000000000000000000000000000000000000000000000000000029a000000000000000000000000000000000000000000000000000000000000000800000000000000000000000047938b89db2377505df98a9b9a92ce97b5a236d90000000000000000000000003635ef8adb194cdaec5b542af8ada8dbedf54b2f0000000000000000000000006e590ef64abbaade91e358feb46295df3365a8e6000000000000000000000000dce671e7301061e0717961f2a3891a24b01c12b7000000000000000000000000ca9dbb919a563d6de2999e071ce77e51690e8bfd000000000000000000000000402905d2aa5d66515d51faf2dfa4e350634dd20a0000000000000000000000009f613f77413c9c08b415c8acca7bde9d060d6a900000000000000000000000005249ec348eb8cd970778f6f9f8e38ff2400d7634

Deployed Bytecode

0x6080604052600436106102e85760003560e01c80636aaa571d11610190578063c87b56dd116100dc578063e985e9c511610095578063eceecdad1161006f578063eceecdad14610964578063f2fde38b14610977578063f421764814610997578063ff1b6556146109b757610331565b8063e985e9c5146108e6578063ea7523ee1461092f578063ecad582a1461094457610331565b8063c87b56dd14610830578063cadf7c4d14610850578063ce7c2ac214610870578063de8801e5146108a6578063e33b7de3146108bc578063e8a3d485146108d157610331565b80638da5cb5b116101495780639852595c116101235780639852595c146107a5578063a22cb465146107db578063b88d4fde146107fb578063c721f08d1461081b57610331565b80638da5cb5b14610752578063938e3d7b1461077057806395d89b411461079057610331565b80636aaa571d146106b2578063704b6c02146106c857806370a08231146106e8578063715018a614610708578063895fc7881461071d5780638b83209b1461073257610331565b8063385b7b311161024f5780634f6ccce7116102085780635e5c06e2116101e25780635e5c06e2146105dd578063616d0dfd146106685780636352211e1461067d57806369d895751461069d57610331565b80634f6ccce71461056c57806355f804b31461058c57806358d21178146105ac57610331565b8063385b7b31146104d25780633a98ef39146104e85780633e78b91c146104fd57806342842e0e1461051d578063464968e61461053d5780634f5e0b281461055257610331565b806319165587116102a15780631916558714610426578063229f3e291461044657806323b872dd1461045c5780632f745c591461047c578063320f62981461049c57806333bc1c5c146104bc57610331565b806301ffc9a71461033657806306fdde031461036b578063081812fc1461038d578063095ea7b3146103c557806310969523146103e757806318160ddd1461040757610331565b36610331577f6ef95f06320e7a25a04a175ca677b7052bdd97131872c2192525a629f51be77033604080516001600160a01b0390921682523460208301520160405180910390a1005b600080fd5b34801561034257600080fd5b506103566103513660046132be565b6109cc565b60405190151581526020015b60405180910390f35b34801561037757600080fd5b506103806109f9565b60405161036291906133ec565b34801561039957600080fd5b506103ad6103a836600461333c565b610a8b565b6040516001600160a01b039091168152602001610362565b3480156103d157600080fd5b506103e56103e0366004613171565b610b25565b005b3480156103f357600080fd5b506103e56104023660046132f6565b610c3b565b34801561041357600080fd5b506009545b604051908152602001610362565b34801561043257600080fd5b506103e561044136600461302f565b610c92565b34801561045257600080fd5b5061041860185481565b34801561046857600080fd5b506103e5610477366004613083565b610e63565b34801561048857600080fd5b50610418610497366004613171565b610e94565b3480156104a857600080fd5b506103e56104b736600461319c565b610f2a565b3480156104c857600080fd5b5061041860195481565b3480156104de57600080fd5b5061041861271081565b3480156104f457600080fd5b50600b54610418565b34801561050957600080fd5b506103e561051836600461319c565b611035565b34801561052957600080fd5b506103e5610538366004613083565b611140565b34801561054957600080fd5b506103e561115b565b34801561055e57600080fd5b506015546103569060ff1681565b34801561057857600080fd5b5061041861058736600461333c565b61122d565b34801561059857600080fd5b506103e56105a73660046132f6565b6112ce565b3480156105b857600080fd5b5060175460185460195460408051938452602084019290925290820152606001610362565b3480156105e957600080fd5b506106356105f836600461302f565b601a6020526000908152604090208054600182015460028301546003909301549192909160ff808216916101008104821691620100009091041686565b604080519687526020870195909552938501929092521515606084015215156080830152151560a082015260c001610362565b34801561067457600080fd5b506103e561131e565b34801561068957600080fd5b506103ad61069836600461333c565b611354565b3480156106a957600080fd5b506103e56113cb565b3480156106be57600080fd5b5061041860165481565b3480156106d457600080fd5b506103e56106e336600461302f565b611468565b3480156106f457600080fd5b5061041861070336600461302f565b6114c9565b34801561071457600080fd5b506103e5611550565b34801561072957600080fd5b506103e5611586565b34801561073e57600080fd5b506103ad61074d36600461333c565b611759565b34801561075e57600080fd5b506000546001600160a01b03166103ad565b34801561077c57600080fd5b506103e561078b3660046132f6565b611797565b34801561079c57600080fd5b506103806117e7565b3480156107b157600080fd5b506104186107c036600461302f565b6001600160a01b03166000908152600e602052604090205490565b3480156107e757600080fd5b506103e56107f6366004613140565b6117f6565b34801561080757600080fd5b506103e56108163660046130c3565b6118c8565b34801561082757600080fd5b506103e5611900565b34801561083c57600080fd5b5061038061084b36600461333c565b611939565b34801561085c57600080fd5b506103e561086b36600461319c565b611a14565b34801561087c57600080fd5b5061041861088b36600461302f565b6001600160a01b03166000908152600d602052604090205490565b3480156108b257600080fd5b5061041860175481565b3480156108c857600080fd5b50600c54610418565b3480156108dd57600080fd5b50610380611b20565b3480156108f257600080fd5b5061035661090136600461304b565b6001600160a01b03918216600090815260066020908152604080832093909416825291909152205460ff1690565b34801561093b57600080fd5b506103e5611b2f565b34801561095057600080fd5b506103e561095f36600461323a565b611b6c565b6103e561097236600461333c565b611c96565b34801561098357600080fd5b506103e561099236600461302f565b6121ba565b3480156109a357600080fd5b506103e56109b236600461319c565b612252565b3480156109c357600080fd5b5061038061236b565b60006001600160e01b0319821663780e9d6360e01b14806109f157506109f1826123f9565b90505b919050565b606060018054610a0890613632565b80601f0160208091040260200160405190810160405280929190818152602001828054610a3490613632565b8015610a815780601f10610a5657610100808354040283529160200191610a81565b820191906000526020600020905b815481529060010190602001808311610a6457829003601f168201915b5050505050905090565b6000818152600360205260408120546001600160a01b0316610b095760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084015b60405180910390fd5b506000908152600560205260409020546001600160a01b031690565b6000610b3082611354565b9050806001600160a01b0316836001600160a01b03161415610b9e5760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610b00565b336001600160a01b0382161480610bba5750610bba8133610901565b610c2c5760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610b00565b610c368383612449565b505050565b6000546001600160a01b03163314610c655760405162461bcd60e51b8152600401610b0090613451565b60155462010000900460ff1615610c7b57600080fd5b8051610c8e906012906020840190612f3e565b5050565b6001600160a01b0381166000908152600d6020526040902054610d065760405162461bcd60e51b815260206004820152602660248201527f5061796d656e7453706c69747465723a206163636f756e7420686173206e6f2060448201526573686172657360d01b6064820152608401610b00565b6000600c5447610d1691906135a4565b6001600160a01b0383166000908152600e6020908152604080832054600b54600d909352908320549394509192610d4d90856135d0565b610d5791906135bc565b610d6191906135ef565b905080610dc45760405162461bcd60e51b815260206004820152602b60248201527f5061796d656e7453706c69747465723a206163636f756e74206973206e6f742060448201526a191d59481c185e5b595b9d60aa1b6064820152608401610b00565b6001600160a01b0383166000908152600e6020526040902054610de89082906135a4565b6001600160a01b0384166000908152600e6020526040902055600c54610e0f9082906135a4565b600c55610e1c83826124b7565b604080516001600160a01b0385168152602081018390527fdf20fd1e76bc69d672e4814fafb2c449bba3a5369d8359adf9e05e6fde87b056910160405180910390a1505050565b610e6d33826125d0565b610e895760405162461bcd60e51b8152600401610b00906134fe565b610c368383836126c7565b6000610e9f836114c9565b8210610f015760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201526a74206f6620626f756e647360a81b6064820152608401610b00565b506001600160a01b03919091166000908152600760209081526040808320938352929052205490565b336000908152601a602052604090206003015462010000900460ff161515600114610f675760405162461bcd60e51b8152600401610b00906134bd565b60005b8151811015610c8e57600a601a6000848481518110610f9957634e487b7160e01b600052603260045260246000fd5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600101819055506001601a6000848481518110610fee57634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b03168252810191909152604001600020600301805460ff19169115159190911790558061102d8161366d565b915050610f6a565b336000908152601a602052604090206003015462010000900460ff1615156001146110725760405162461bcd60e51b8152600401610b00906134bd565b60005b8151811015610c8e576005601a60008484815181106110a457634e487b7160e01b600052603260045260246000fd5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600101819055506001601a60008484815181106110f957634e487b7160e01b600052603260045260246000fd5b6020908102919091018101516001600160a01b03168252810191909152604001600020600301805460ff1916911515919091179055806111388161366d565b915050611075565b610c36838383604051806020016040528060008152506118c8565b336000908152601a602052604090206003015462010000900460ff1615156001146111985760405162461bcd60e51b8152600401610b00906134bd565b6016546111a7906127106135ef565b6009546111b59060026135a4565b11156111d35760405162461bcd60e51b8152600401610b0090613486565b601d546111ea906001600160a01b03166001612872565b601d54611201906001600160a01b03166002612872565b3360008051602061370a83398151915261121a60095490565b60405190815260200160405180910390a2565b600061123860095490565b821061129b5760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201526b7574206f6620626f756e647360a01b6064820152608401610b00565b600982815481106112bc57634e487b7160e01b600052603260045260246000fd5b90600052602060002001549050919050565b336000908152601a602052604090206003015462010000900460ff16151560011461130b5760405162461bcd60e51b8152600401610b00906134bd565b8051610c8e906013906020840190612f3e565b6000546001600160a01b031633146113485760405162461bcd60e51b8152600401610b0090613451565b6015805460ff19169055565b6000818152600360205260408120546001600160a01b0316806109f15760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610b00565b336000908152601a602052604090206003015462010000900460ff1615156001146114085760405162461bcd60e51b8152600401610b00906134bd565b60005b601b5481101561146557611453601b828154811061143957634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546001600160a01b0316610c92565b8061145d8161366d565b91505061140b565b50565b6000546001600160a01b031633146114925760405162461bcd60e51b8152600401610b0090613451565b6001600160a01b03166000908152601a60205260409020600301805462ff0000198116620100009182900460ff1615909102179055565b60006001600160a01b0382166115345760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610b00565b506001600160a01b031660009081526004602052604090205490565b6000546001600160a01b0316331461157a5760405162461bcd60e51b8152600401610b0090613451565b611584600061288c565b565b336000908152601a602052604090206003015462010000900460ff1615156001146115c35760405162461bcd60e51b8152600401610b00906134bd565b336000908152601a60205260409020805460039091015462010000900460ff1615156001146116345760405162461bcd60e51b815260206004820181905260248201527f4e6963652054727921204f6e6c7920616e2061646d696e2063616e206d696e746044820152606401610b00565b600081116116845760405162461bcd60e51b815260206004820152601c60248201527f4e65656420746f206861766520726573657276656420737570706c79000000006044820152606401610b00565b6127108161169160095490565b61169b91906135a4565b11156116b95760405162461bcd60e51b8152600401610b0090613486565b336000908152601a6020526040812080548392906116d89084906135ef565b90915550506016546116eb9082906135ef565b60165560006116f960095490565b905060005b82811015610c3657816117108161366d565b92505061171d3383612872565b3360008051602061370a83398151915261173660095490565b60405190815260200160405180910390a2806117518161366d565b9150506116fe565b6000600f828154811061177c57634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546001600160a01b031692915050565b336000908152601a602052604090206003015462010000900460ff1615156001146117d45760405162461bcd60e51b8152600401610b00906134bd565b8051610c8e906014906020840190612f3e565b606060028054610a0890613632565b6001600160a01b03821633141561184f5760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610b00565b3360008181526006602090815260408083206001600160a01b0387168085529252909120805460ff1916841515179055906001600160a01b03167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31836040516118bc911515815260200190565b60405180910390a35050565b6118d233836125d0565b6118ee5760405162461bcd60e51b8152600401610b00906134fe565b6118fa848484846128dc565b50505050565b6000546001600160a01b0316331461192a5760405162461bcd60e51b8152600401610b0090613451565b6015805460ff19166001179055565b6000818152600360205260409020546060906001600160a01b03166119b85760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b6064820152608401610b00565b60006119c261290f565b905060008151116119e25760405180602001604052806000815250611a0d565b806119ec8461291e565b6040516020016119fd929190613380565b6040516020818303038152906040525b9392505050565b336000908152601a602052604090206003015462010000900460ff161515600114611a515760405162461bcd60e51b8152600401610b00906134bd565b601654611a60906127106135ef565b8151600954611a6f91906135a4565b1115611a8d5760405162461bcd60e51b8152600401610b0090613486565b6000611a9860095490565b905060005b8251811015610c365781611ab08161366d565b925050611ae4838281518110611ad657634e487b7160e01b600052603260045260246000fd5b602002602001015183612872565b3360008051602061370a833981519152611afd60095490565b60405190815260200160405180910390a280611b188161366d565b915050611a9d565b606060148054610a0890613632565b6000546001600160a01b03163314611b595760405162461bcd60e51b8152600401610b0090613451565b6015805462ff0000191662010000179055565b336000908152601a602052604090206003015462010000900460ff161515600114611ba95760405162461bcd60e51b8152600401610b00906134bd565b8051600314611c065760405162461bcd60e51b8152602060048201526024808201527f596f75206e65656420746f2075706461746520616c6c2074696d6573206174206044820152636f6e636560e01b6064820152608401610b00565b80600081518110611c2757634e487b7160e01b600052603260045260246000fd5b602002602001015160178190555080600181518110611c5657634e487b7160e01b600052603260045260246000fd5b602002602001015160188190555080600281518110611c8557634e487b7160e01b600052603260045260246000fd5b602002602001015160198190555050565b601554610100900460ff1615611cdf5760405162461bcd60e51b815260206004820152600e60248201526d4e6f2072652d656e7472616e637960901b6044820152606401610b00565b6015805461ff001916610100179081905560ff16611d3f5760405162461bcd60e51b815260206004820152601b60248201527f53616c65206d7573742062652061637469766520746f206d696e7400000000006044820152606401610b00565b601754421015611da35760405162461bcd60e51b815260206004820152602960248201527f596f75206d75737420776169742074696c6c2070726573616c6520626567696e6044820152681cc81d1bc81b5a5b9d60ba1b6064820152608401610b00565b60008111611e055760405162461bcd60e51b815260206004820152602960248201527f4d757374206d696e74206174206c65617374206f6e6520746f6b656e20616e64604482015268020756e6465722031360bc1b6064820152608401610b00565b601654611e14906127106135ef565b81611e1e60095490565b611e2891906135a4565b1115611e875760405162461bcd60e51b815260206004820152602860248201527f507572636861736520776f756c6420657863656564206d617820737570706c79604482015267206f66204170657360c01b6064820152608401610b00565b80601054611e9591906135d0565b341015611ee45760405162461bcd60e51b815260206004820152601f60248201527f45746865722076616c75652073656e74206973206e6f7420636f7272656374006044820152606401610b00565b333b15611f2a5760405162461bcd60e51b815260206004820152601460248201527310dbdb9d1c9858dd1cc818d85b89dd081b5a5b9d60621b6044820152606401610b00565b6019544210611fb257601154336000908152601a6020526040902060020154611f5390836135a4565b1115611fad5760405162461bcd60e51b8152602060048201526024808201527f536f72727920796f752063616e206f6e6c79206d696e742033207065722077616044820152631b1b195d60e21b6064820152608401610b00565b61211a565b601854421061201a5760405162461bcd60e51b815260206004820152602e60248201527f50726573616c652068617320456e64656420706c65617365205761697420746960448201526d6c6c205075626c69632073616c6560901b6064820152608401610b00565b601754421061211a57336000908152601a6020526040902060030154610100900460ff168061205b5750336000908152601a602052604090206003015460ff165b6120b15760405162461bcd60e51b815260206004820152602160248201527f536f72727920796f75206e65656420746f206265206f6e2057686974656c69736044820152601d60fa1b6064820152608401610b00565b336000908152601a6020526040902060018101546002909101546120d590836135a4565b111561211a5760405162461bcd60e51b815260206004820152601460248201527315d85b1b195d08131a5b5a5d0814995858da195960621b6044820152606401610b00565b600061212560095490565b905060005b828110156121aa578161213c8161366d565b336000908152601a60205260408120600201805492955091925061215f8361366d565b919050555061216e3383612872565b3360008051602061370a83398151915261218760095490565b60405190815260200160405180910390a2806121a28161366d565b91505061212a565b50506015805461ff001916905550565b6000546001600160a01b031633146121e45760405162461bcd60e51b8152600401610b0090613451565b6001600160a01b0381166122495760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610b00565b6114658161288c565b336000908152601a602052604090206003015462010000900460ff16151560011461228f5760405162461bcd60e51b8152600401610b00906134bd565b60005b8151811015610c8e576002601a60008484815181106122c157634e487b7160e01b600052603260045260246000fd5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600101819055506001601a600084848151811061231657634e487b7160e01b600052603260045260246000fd5b60200260200101516001600160a01b03166001600160a01b0316815260200190815260200160002060030160016101000a81548160ff02191690831515021790555080806123639061366d565b915050612292565b6012805461237890613632565b80601f01602080910402602001604051908101604052809291908181526020018280546123a490613632565b80156123f15780601f106123c6576101008083540402835291602001916123f1565b820191906000526020600020905b8154815290600101906020018083116123d457829003601f168201915b505050505081565b60006001600160e01b031982166380ac58cd60e01b148061242a57506001600160e01b03198216635b5e139f60e01b145b806109f157506301ffc9a760e01b6001600160e01b03198316146109f1565b600081815260056020526040902080546001600160a01b0319166001600160a01b038416908117909155819061247e82611354565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b804710156125075760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e63650000006044820152606401610b00565b6000826001600160a01b03168260405160006040518083038185875af1925050503d8060008114612554576040519150601f19603f3d011682016040523d82523d6000602084013e612559565b606091505b5050905080610c365760405162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152608401610b00565b6000818152600360205260408120546001600160a01b03166126495760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610b00565b600061265483611354565b9050806001600160a01b0316846001600160a01b0316148061268f5750836001600160a01b031661268484610a8b565b6001600160a01b0316145b806126bf57506001600160a01b0380821660009081526006602090815260408083209388168352929052205460ff165b949350505050565b826001600160a01b03166126da82611354565b6001600160a01b0316146127425760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b6064820152608401610b00565b6001600160a01b0382166127a45760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610b00565b6127af838383612a39565b6127ba600082612449565b6001600160a01b03831660009081526004602052604081208054600192906127e39084906135ef565b90915550506001600160a01b03821660009081526004602052604081208054600192906128119084906135a4565b909155505060008181526003602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b610c8e828260405180602001604052806000815250612af6565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6128e78484846126c7565b6128f384848484612b29565b6118fa5760405162461bcd60e51b8152600401610b00906133ff565b606060138054610a0890613632565b60608161294357506040805180820190915260018152600360fc1b60208201526109f4565b8160005b811561296d57806129578161366d565b91506129669050600a836135bc565b9150612947565b60008167ffffffffffffffff81111561299657634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f1916602001820160405280156129c0576020820181803683370190505b5090505b84156126bf576129d56001836135ef565b91506129e2600a86613688565b6129ed9060306135a4565b60f81b818381518110612a1057634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a905350612a32600a866135bc565b94506129c4565b6001600160a01b038316612a9457612a8f81600980546000838152600a60205260408120829055600182018355919091527f6e1540171b6c0c960b71a7020d9f60077f6af931a8bbf590da0223dacf75c7af0155565b612ab7565b816001600160a01b0316836001600160a01b031614612ab757612ab78382612c36565b6001600160a01b038216612ad357612ace81612cd3565b610c36565b826001600160a01b0316826001600160a01b031614610c3657610c368282612dac565b612b008383612df0565b612b0d6000848484612b29565b610c365760405162461bcd60e51b8152600401610b00906133ff565b60006001600160a01b0384163b15612c2b57604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290612b6d9033908990889088906004016133af565b602060405180830381600087803b158015612b8757600080fd5b505af1925050508015612bb7575060408051601f3d908101601f19168201909252612bb4918101906132da565b60015b612c11573d808015612be5576040519150601f19603f3d011682016040523d82523d6000602084013e612bea565b606091505b508051612c095760405162461bcd60e51b8152600401610b00906133ff565b805181602001fd5b6001600160e01b031916630a85bd0160e11b1490506126bf565b506001949350505050565b60006001612c43846114c9565b612c4d91906135ef565b600083815260086020526040902054909150808214612ca0576001600160a01b03841660009081526007602090815260408083208584528252808320548484528184208190558352600890915290208190555b5060009182526008602090815260408084208490556001600160a01b039094168352600781528383209183525290812055565b600954600090612ce5906001906135ef565b6000838152600a602052604081205460098054939450909284908110612d1b57634e487b7160e01b600052603260045260246000fd5b906000526020600020015490508060098381548110612d4a57634e487b7160e01b600052603260045260246000fd5b6000918252602080832090910192909255828152600a90915260408082208490558582528120556009805480612d9057634e487b7160e01b600052603160045260246000fd5b6001900381819060005260206000200160009055905550505050565b6000612db7836114c9565b6001600160a01b039093166000908152600760209081526040808320868452825280832085905593825260089052919091209190915550565b6001600160a01b038216612e465760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610b00565b6000818152600360205260409020546001600160a01b031615612eab5760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610b00565b612eb760008383612a39565b6001600160a01b0382166000908152600460205260408120805460019290612ee09084906135a4565b909155505060008181526003602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b828054612f4a90613632565b90600052602060002090601f016020900481019282612f6c5760008555612fb2565b82601f10612f8557805160ff1916838001178555612fb2565b82800160010185558215612fb2579182015b82811115612fb2578251825591602001919060010190612f97565b50612fbe929150612fc2565b5090565b5b80821115612fbe5760008155600101612fc3565b600067ffffffffffffffff831115612ff157612ff16136c8565b613004601f8401601f191660200161354f565b905082815283838301111561301857600080fd5b828260208301376000602084830101529392505050565b600060208284031215613040578081fd5b8135611a0d816136de565b6000806040838503121561305d578081fd5b8235613068816136de565b91506020830135613078816136de565b809150509250929050565b600080600060608486031215613097578081fd5b83356130a2816136de565b925060208401356130b2816136de565b929592945050506040919091013590565b600080600080608085870312156130d8578081fd5b84356130e3816136de565b935060208501356130f3816136de565b925060408501359150606085013567ffffffffffffffff811115613115578182fd5b8501601f81018713613125578182fd5b61313487823560208401612fd7565b91505092959194509250565b60008060408385031215613152578182fd5b823561315d816136de565b915060208301358015158114613078578182fd5b60008060408385031215613183578182fd5b823561318e816136de565b946020939093013593505050565b600060208083850312156131ae578182fd5b823567ffffffffffffffff8111156131c4578283fd5b8301601f810185136131d4578283fd5b80356131e76131e282613580565b61354f565b8181528381019083850185840285018601891015613203578687fd5b8694505b8385101561322e57803561321a816136de565b835260019490940193918501918501613207565b50979650505050505050565b6000602080838503121561324c578182fd5b823567ffffffffffffffff811115613262578283fd5b8301601f81018513613272578283fd5b80356132806131e282613580565b818152838101908385018584028501860189101561329c578687fd5b8694505b8385101561322e5780358352600194909401939185019185016132a0565b6000602082840312156132cf578081fd5b8135611a0d816136f3565b6000602082840312156132eb578081fd5b8151611a0d816136f3565b600060208284031215613307578081fd5b813567ffffffffffffffff81111561331d578182fd5b8201601f8101841361332d578182fd5b6126bf84823560208401612fd7565b60006020828403121561334d578081fd5b5035919050565b6000815180845261336c816020860160208601613606565b601f01601f19169290920160200192915050565b60008351613392818460208801613606565b8351908301906133a6818360208801613606565b01949350505050565b6001600160a01b03858116825284166020820152604081018390526080606082018190526000906133e290830184613354565b9695505050505050565b600060208252611a0d6020830184613354565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b6020808252601a908201527f596f7520776f756c642065786365656420746865206c696d6974000000000000604082015260600190565b60208082526021908201527f4e696365207472792120596f75206e65656420746f20626520616e2061646d696040820152603760f91b606082015260800190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b604051601f8201601f1916810167ffffffffffffffff81118282101715613578576135786136c8565b604052919050565b600067ffffffffffffffff82111561359a5761359a6136c8565b5060209081020190565b600082198211156135b7576135b761369c565b500190565b6000826135cb576135cb6136b2565b500490565b60008160001904831182151516156135ea576135ea61369c565b500290565b6000828210156136015761360161369c565b500390565b60005b83811015613621578181015183820152602001613609565b838111156118fa5750506000910152565b60028104600182168061364657607f821691505b6020821081141561366757634e487b7160e01b600052602260045260246000fd5b50919050565b60006000198214156136815761368161369c565b5060010190565b600082613697576136976136b2565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b038116811461146557600080fd5b6001600160e01b03198116811461146557600080fdfe0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d4121396885a2646970667358221220153eb3788e0a6eb07355e2bb42dcf46cb237ba385911dab5b3a7d15bc93838bc64736f6c63430008020033

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

00000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000020000000000000000000000000047ef4eb0d047daf2fa7152c5f9ba8fc4ea5a957f0000000000000000000000000000000000000000000000000000000000000005000000000000000000000000b80ed04daf88401f20752bb40490b82f73de8687000000000000000000000000c43b7017871c611a23366584c487dc3aaf3c09ec000000000000000000000000ad8259e83b4a48a97360edcb808a2d2bf3ace1910000000000000000000000005f7aac1728f23cb06ba806741f0fff373eb581ba00000000000000000000000067aaef4a6f49a27cf90789ead73ba1d189b050d300000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000fa00000000000000000000000000000000000000000000000000000000000000fa0000000000000000000000000000000000000000000000000000000000000029b000000000000000000000000000000000000000000000000000000000000029b000000000000000000000000000000000000000000000000000000000000029a000000000000000000000000000000000000000000000000000000000000000800000000000000000000000047938b89db2377505df98a9b9a92ce97b5a236d90000000000000000000000003635ef8adb194cdaec5b542af8ada8dbedf54b2f0000000000000000000000006e590ef64abbaade91e358feb46295df3365a8e6000000000000000000000000dce671e7301061e0717961f2a3891a24b01c12b7000000000000000000000000ca9dbb919a563d6de2999e071ce77e51690e8bfd000000000000000000000000402905d2aa5d66515d51faf2dfa4e350634dd20a0000000000000000000000009f613f77413c9c08b415c8acca7bde9d060d6a900000000000000000000000005249ec348eb8cd970778f6f9f8e38ff2400d7634

-----Decoded View---------------
Arg [0] : team (address[]): 0xB80Ed04DAf88401f20752bB40490B82f73de8687,0xc43b7017871c611a23366584C487dc3aaf3C09EC,0xad8259E83B4a48a97360eDcb808A2D2bf3aCE191,0x5F7aAc1728F23cB06bA806741F0Fff373Eb581bA,0x67aaEf4a6F49A27cf90789EAD73ba1D189B050D3
Arg [1] : team_shares (uint256[]): 4000,4000,667,667,666
Arg [2] : admins (address[]): 0x47938b89db2377505Df98A9b9A92Ce97B5a236D9,0x3635eF8Adb194cDAeC5B542aF8ADA8DBeDF54b2f,0x6e590EF64aBBAade91E358FEB46295df3365A8e6,0xdce671E7301061E0717961F2A3891a24b01c12b7,0xCA9DBB919a563D6dE2999e071Ce77e51690E8BFd,0x402905d2AA5D66515D51FAF2dFA4e350634dd20A,0x9f613f77413C9c08b415c8ACCA7bdE9d060D6A90,0x5249Ec348EB8cD970778f6F9f8e38Ff2400D7634
Arg [3] : d1 (address): 0x47Ef4Eb0d047Daf2FA7152c5F9Ba8FC4Ea5A957F

-----Encoded View---------------
25 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000080
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000140
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000200
Arg [3] : 00000000000000000000000047ef4eb0d047daf2fa7152c5f9ba8fc4ea5a957f
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000005
Arg [5] : 000000000000000000000000b80ed04daf88401f20752bb40490b82f73de8687
Arg [6] : 000000000000000000000000c43b7017871c611a23366584c487dc3aaf3c09ec
Arg [7] : 000000000000000000000000ad8259e83b4a48a97360edcb808a2d2bf3ace191
Arg [8] : 0000000000000000000000005f7aac1728f23cb06ba806741f0fff373eb581ba
Arg [9] : 00000000000000000000000067aaef4a6f49a27cf90789ead73ba1d189b050d3
Arg [10] : 0000000000000000000000000000000000000000000000000000000000000005
Arg [11] : 0000000000000000000000000000000000000000000000000000000000000fa0
Arg [12] : 0000000000000000000000000000000000000000000000000000000000000fa0
Arg [13] : 000000000000000000000000000000000000000000000000000000000000029b
Arg [14] : 000000000000000000000000000000000000000000000000000000000000029b
Arg [15] : 000000000000000000000000000000000000000000000000000000000000029a
Arg [16] : 0000000000000000000000000000000000000000000000000000000000000008
Arg [17] : 00000000000000000000000047938b89db2377505df98a9b9a92ce97b5a236d9
Arg [18] : 0000000000000000000000003635ef8adb194cdaec5b542af8ada8dbedf54b2f
Arg [19] : 0000000000000000000000006e590ef64abbaade91e358feb46295df3365a8e6
Arg [20] : 000000000000000000000000dce671e7301061e0717961f2a3891a24b01c12b7
Arg [21] : 000000000000000000000000ca9dbb919a563d6de2999e071ce77e51690e8bfd
Arg [22] : 000000000000000000000000402905d2aa5d66515d51faf2dfa4e350634dd20a
Arg [23] : 0000000000000000000000009f613f77413c9c08b415c8acca7bde9d060d6a90
Arg [24] : 0000000000000000000000005249ec348eb8cd970778f6f9f8e38ff2400d7634


Loading...
Loading
Loading...
Loading
[ Download: CSV Export  ]
[ Download: CSV Export  ]

A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.