Contract 0xf016e69f2c08a0b743a7d815d1059318dca8fc0e

Contract Overview

Balance:
0 AVAX

AVAX Value:
$0.00

Token:
Txn Hash Method
Block
From
To
Value [Txn Fee]
0xd066ea0a51bfee1b50a54cbbda617d8f6f73afe98a8d4b5dfe1aecc09efc48d0Stake188461212022-08-19 13:15:154 mins ago0xb5145d6e514f7f27ecb19d64bcbc4cb8a8f9cf88 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001687838 26.‍5
0xfd64703b4616b5ac81d4862a04891d5697975478b706eca68a7080685b939d0bStake188458552022-08-19 13:06:2113 mins ago0x1d8f4ccb51fb3d2e5fa4f2daa1c994f603b0ef47 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001688156 26.‍5
0xe50cc272e015f5ca227b64af18c82e551bdf34d61597272a813de38d1d3394f2Stake188453452022-08-19 12:49:1830 mins ago0xdf0caded8b4dc407363a1bfe13a5721188619e31 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001687838 26.‍5
0x6c115b0d8ca483dbd6134eecde8fca3dd819c695c5873b657dfaa88f487772adStake188450152022-08-19 12:38:2141 mins ago0xdf0caded8b4dc407363a1bfe13a5721188619e31 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001687838 26.‍5
0xac4cd9c8b229a452eac30e5af041c008b0f574997252a5a4756b06b8bf939af6Stake188445812022-08-19 12:23:5156 mins ago0xc6c3c471e64fec8684988d04dead9a4e1f98587d IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001688156 26.‍5
0xe408fab6ce3c7e9703dba331e0c51ff6031bb035cbb408f83135067fc4e755f9Stake188442902022-08-19 12:14:091 hr 5 mins ago0x2f008c0ae2e1460cf783eea2e76b2cd4ffc3d7a0 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001687838 26.‍5
0xb4d5e470fc2d6112070f8c38e5d11fcaa66fff415a3269aa0bfe3dd88c52d413Claim Delayed Un...188440892022-08-19 12:07:241 hr 12 mins ago0x03ce8f892155eb33da2a038cf97f415068841365 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001176494 26.‍5
0x6408d89d4a596e7181a0dd50627af2dc9050b4d3795eaa5aa020389e7b5108faStake188434532022-08-19 11:46:081 hr 33 mins ago0x1c4454aecd54bae4c74a7ddb39334db62e9bcf81 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001694641712 26.‍606822096
0x42b5533791cdddb021237c189894a610188c40a2592affdeeff4465cf0bab774Stake188423902022-08-19 11:10:372 hrs 9 mins ago0x2401f45a0617c51e9e1915df4a6869aea1cf61fd IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍00177824355 27.‍919417681
0xcdf753bfb15f589b14fc0636d928c397150b6eec8107db462b9a4b8ff8e43357Approve188419732022-08-19 10:56:482 hrs 23 mins ago0x9a21fe4f4ee54882d5d49298d322b1cd4f20bc5f IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001235271 26.‍5
0x43e8c89c096de000551bc001552e77e2bec49dd31fdec0f4185ba9da592c26c5Stake188411582022-08-19 10:28:592 hrs 51 mins ago0x14a353b5aaf224db40ee1a5513f0cfdef2567380 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001687838 26.‍5
0x0fd7d464b3b2591e1907ec8ed660c52a7768e1793767cbd3a81ec5a982e32df3Stake188408092022-08-19 10:17:183 hrs 2 mins ago0x9a379096dbf27099c0bbe112d03bd1cd2f3425c3 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001688156 26.‍5
0x0d7c1165bad8606708ef2c4e46361b238fc5cb4ae88c24dae272fcd4ce7c0543Stake188405972022-08-19 10:10:113 hrs 9 mins ago0x132f3e094f098b8050ef1afe388b6acf19a1debb IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001701584341 26.‍71582524
0x851126f51d2090c66b60702c43a980a2511239270e3fcd063a89710f9ea6fedaStake188405292022-08-19 10:07:553 hrs 12 mins ago0xf494dd5d303f614ed84d46bd5c14fffc658ebf7d IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001688156 26.‍5
0x21f2bd5d90cc4eb6f14b2dd718a326fac2096c38ce787d527566cc50890e57bcStake188403512022-08-19 10:01:493 hrs 18 mins ago0x22b226925a70d51856e73fcd2d23bc176f66d3c9 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001688156 26.‍5
0x6bd526e58f9f820c06c8f2526c6ca514e3e55a7ab8a6a422efdee29af81afd0fStake188403222022-08-19 10:00:503 hrs 19 mins ago0x22b226925a70d51856e73fcd2d23bc176f66d3c9 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001687838 26.‍5
0x3285ba66d5de161ae0793fecc4cda2ff059346336ffb0bdedbc9b0d33d051e62Approve188401472022-08-19 9:54:493 hrs 25 mins ago0xfac36a189d27b04eb246105081895c61cca6dfd6 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001235271 26.‍5
0x1fa2f9bdb1061c8e0738bd5561feb79ff611e2047da1eb4b54fc6c7d96818e94Stake188401292022-08-19 9:54:133 hrs 25 mins ago0xfac36a189d27b04eb246105081895c61cca6dfd6 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍0021631704 26.‍77058562
0xcf110ef53988d289e0512005d1596eaa4e7d57902c5f4b6ec5588abdaf0e0558Stake188398792022-08-19 9:45:493 hrs 34 mins ago0x57b18069f62f7d2a9aa6617b9f7b2e5ad9f32133 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001687838 26.‍5
0xa8809ba6e9673e9cfbd25436b586e2e330db6fd77475a1980280ee0284e281a2Stake188396962022-08-19 9:39:443 hrs 40 mins ago0x66e00965f70ccda9727e07583cbf22b442519013 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001712478187 26.‍8818
0xbe77b4c81f06f4ba044bca8f3d8bf14f1799820ecf655d05706c5b04b25a98b7Stake188392002022-08-19 9:23:003 hrs 57 mins ago0x58235e19b7d6b1852f21649ec185a13afa183248 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001688156 26.‍5
0x6237b561c9bf8457cbd087516f402b9096b9ba472239de756bafc937e193e66fClaim Delayed Un...188385702022-08-19 9:01:264 hrs 18 mins ago0x702bd8565e7e6fe3eb3a4c29cff46671ca816477 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001176494 26.‍5
0xca56f9620da25f3325ebb36371d139b131c148b207e095582f81bb9af6cef2dcStake188385412022-08-19 9:00:284 hrs 19 mins ago0x702bd8565e7e6fe3eb3a4c29cff46671ca816477 IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001687838 26.‍5
0x23a1331db474924fb3090a176ad8c31948e93a7abe5f1b6f25c9a0365a885a67Stake188377192022-08-19 8:32:294 hrs 47 mins ago0xce50c962a2ccf4c7dad818fc9b68ebeffb6a810a IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001688156 26.‍5
0x15096ff87dcd8ddce2226fd3577a08ad1df4da97166c15cbc02a82be1f4c7865Stake188375802022-08-19 8:27:514 hrs 52 mins ago0xc6c3c471e64fec8684988d04dead9a4e1f98587d IN  0xf016e69f2c08a0b743a7d815d1059318dca8fc0e0 AVAX0.‍001712478187 26.‍8818
[ Download CSV Export 
Parent Txn Hash Block From To Value
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
Cellar

Compiler Version
v0.8.11+commit.d7f03943

Optimization Enabled:
Yes with 100 runs

Other Settings:
default evmVersion

Contract Source Code (Solidity Standard Json-Input format)

File 1 of 11 : Cellar.sol
// Freezer
//SPDX-License-Identifier: Unlicense
pragma solidity ^0.8.4;

import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/utils/math/SafeMath.sol";
import "@openzeppelin/contracts/security/Pausable.sol";

import "./VintageWine.sol";

contract Cellar is
    ERC20("Staked Vintage", "SVINTAGE"),
    Ownable,
    Pausable
{
    using SafeERC20 for VintageWine;
    using SafeMath for uint256;

    uint256 public constant DELAYED_UNSTAKE_LOCKUP_PERIOD = 2 days;
    uint256 public constant DELAYED_UNSTAKE_BURN_PERCENT = 10;
    uint256 public constant QUICK_UNSTAKE_CONTRIBUTION_PERCENT = 50;
    uint256 public constant QUICK_UNSTAKE_BURN_PERCENT = 25;

    VintageWine public vintageWine;
    uint256 public frozenVintageWine; // VINTAGEWINE pending withdrawal

    mapping(address => uint256) public unlockAmounts;
    mapping(address => uint256) public unlockTimestamps;

    uint256 public stakeTime;

    constructor(VintageWine _vintageWine) {
        vintageWine = _vintageWine;
    }

    // Views

    function vintageWineBalance() public view returns (uint256 balance) {
        return vintageWine.balanceOf(address(this)) - frozenVintageWine;
    }

    function _unstakeOutput(uint256 _share)
        internal
        view
        returns (uint256 output)
    {
        uint256 totalShares = totalSupply();
        return _share.mul(vintageWineBalance()).div(totalShares);
    }

    // External

    function stake(uint256 _amount) external whenNotPaused {
        require(stakeStarted(), "You can't stake yet");
        uint256 totalShares = totalSupply();
        // If no sVINTAGEWINE exists, mint it 1:1 to the amount put in
        if (totalShares == 0 || vintageWineBalance() == 0) {
            _mint(_msgSender(), _amount);
        } else {
            uint256 share = _amount.mul(totalShares).div(vintageWineBalance());
            _mint(_msgSender(), share);
        }

        vintageWine.transferToCellar(_msgSender(), _amount);
    }

    function quickUnstake(uint256 _share) external whenNotPaused {
        // QUICK_UNSTAKE_CONTRIBUTION_PERCENT of the claimable VINTAGEWINE will remain in the cellar
        // the rest is transfered to the staker
        uint256 unstakeOutput = _unstakeOutput(_share);
        uint256 output = unstakeOutput
            .mul(100 - QUICK_UNSTAKE_CONTRIBUTION_PERCENT)
            .div(100);
        // QUICK_UNSTAKE_BURN_PERCENT of the claimable VINTAGEWINE is burned
        uint256 amountSpoiled = unstakeOutput
            .mul(QUICK_UNSTAKE_BURN_PERCENT)
            .div(100);

        // burn staker's share
        _burn(_msgSender(), _share);

        vintageWine.burn(address(this), amountSpoiled);
        vintageWine.safeTransfer(_msgSender(), output);
    }

    /**
     * @dev _share argument specified in sVINTAGEWINE
     */
    function prepareDelayedUnstake(uint256 _share) external whenNotPaused {
        // calculate output and burn staker's share
        uint256 output = _unstakeOutput(_share); //converts svintageWine values to vintageWine
        _burn(_msgSender(), _share);

        // calculate and burn amount of output spoiled
        uint256 amountSpoiled = output.mul(DELAYED_UNSTAKE_BURN_PERCENT).div(
            100
        );

        // remove amountSpoiled from output
        output -= amountSpoiled;

        unlockAmounts[_msgSender()] += output;
        unlockTimestamps[_msgSender()] =
            block.timestamp +
            DELAYED_UNSTAKE_LOCKUP_PERIOD;
        frozenVintageWine += output;

        vintageWine.burn(address(this), amountSpoiled);
    }

    /**
     * @dev argument specified in VINTAGEWINE, not sVINTAGEWINE
     */
    function claimDelayedUnstake(uint256 _amount) external whenNotPaused {
        require(
            block.timestamp >= unlockTimestamps[_msgSender()],
            "VINTAGE not yet unlocked"
        );
        require(
            _amount <= unlockAmounts[_msgSender()],
            "insufficient locked balance"
        );

        // deduct from unlocked
        unlockAmounts[_msgSender()] -= _amount;

        frozenVintageWine -= _amount;

        // transfer claim
        vintageWine.safeTransfer(_msgSender(), _amount);
    }

    // Admin

    function stakeStarted() public view returns (bool) {
        return stakeTime != 0 && block.timestamp >= stakeTime;
    }

    function setStakeStartTime(uint256 _startTime) external onlyOwner {
        require(
            _startTime >= block.timestamp,
            "startTime cannot be in the past"
        );
        require(!stakeStarted(), "staking already started");
        stakeTime = _startTime;
    }
}

File 2 of 11 : SafeERC20.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC20/utils/SafeERC20.sol)

pragma solidity ^0.8.0;

import "../IERC20.sol";
import "../../../utils/Address.sol";

/**
 * @title SafeERC20
 * @dev Wrappers around ERC20 operations that throw on failure (when the token
 * contract returns false). Tokens that return no value (and instead revert or
 * throw on failure) are also supported, non-reverting calls are assumed to be
 * successful.
 * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract,
 * which allows you to call the safe operations as `token.safeTransfer(...)`, etc.
 */
library SafeERC20 {
    using Address for address;

    function safeTransfer(
        IERC20 token,
        address to,
        uint256 value
    ) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value));
    }

    function safeTransferFrom(
        IERC20 token,
        address from,
        address to,
        uint256 value
    ) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value));
    }

    /**
     * @dev Deprecated. This function has issues similar to the ones found in
     * {IERC20-approve}, and its usage is discouraged.
     *
     * Whenever possible, use {safeIncreaseAllowance} and
     * {safeDecreaseAllowance} instead.
     */
    function safeApprove(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        // safeApprove should only be called when setting an initial allowance,
        // or when resetting it to zero. To increase and decrease it, use
        // 'safeIncreaseAllowance' and 'safeDecreaseAllowance'
        require(
            (value == 0) || (token.allowance(address(this), spender) == 0),
            "SafeERC20: approve from non-zero to non-zero allowance"
        );
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));
    }

    function safeIncreaseAllowance(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        uint256 newAllowance = token.allowance(address(this), spender) + value;
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    function safeDecreaseAllowance(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        unchecked {
            uint256 oldAllowance = token.allowance(address(this), spender);
            require(oldAllowance >= value, "SafeERC20: decreased allowance below zero");
            uint256 newAllowance = oldAllowance - value;
            _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
        }
    }

    /**
     * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement
     * on the return value: the return value is optional (but if data is returned, it must not be false).
     * @param token The token targeted by the call.
     * @param data The call data (encoded using abi.encode or one of its variants).
     */
    function _callOptionalReturn(IERC20 token, bytes memory data) private {
        // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since
        // we're implementing it ourselves. We use {Address.functionCall} to perform this call, which verifies that
        // the target address contains contract code and also asserts for success in the low-level call.

        bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed");
        if (returndata.length > 0) {
            // Return data is optional
            require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed");
        }
    }
}

File 3 of 11 : ERC20.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/ERC20.sol)

pragma solidity ^0.8.0;

import "./IERC20.sol";
import "./extensions/IERC20Metadata.sol";
import "../../utils/Context.sol";

/**
 * @dev Implementation of the {IERC20} interface.
 *
 * This implementation is agnostic to the way tokens are created. This means
 * that a supply mechanism has to be added in a derived contract using {_mint}.
 * For a generic mechanism see {ERC20PresetMinterPauser}.
 *
 * TIP: For a detailed writeup see our guide
 * https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How
 * to implement supply mechanisms].
 *
 * We have followed general OpenZeppelin Contracts guidelines: functions revert
 * instead returning `false` on failure. This behavior is nonetheless
 * conventional and does not conflict with the expectations of ERC20
 * applications.
 *
 * Additionally, an {Approval} event is emitted on calls to {transferFrom}.
 * This allows applications to reconstruct the allowance for all accounts just
 * by listening to said events. Other implementations of the EIP may not emit
 * these events, as it isn't required by the specification.
 *
 * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}
 * functions have been added to mitigate the well-known issues around setting
 * allowances. See {IERC20-approve}.
 */
contract ERC20 is Context, IERC20, IERC20Metadata {
    mapping(address => uint256) private _balances;

    mapping(address => mapping(address => uint256)) private _allowances;

    uint256 private _totalSupply;

    string private _name;
    string private _symbol;

    /**
     * @dev Sets the values for {name} and {symbol}.
     *
     * The default value of {decimals} is 18. To select a different value for
     * {decimals} you should overload it.
     *
     * All two of these values are immutable: they can only be set once during
     * construction.
     */
    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
    }

    /**
     * @dev Returns the name of the token.
     */
    function name() public view virtual override returns (string memory) {
        return _name;
    }

    /**
     * @dev Returns the symbol of the token, usually a shorter version of the
     * name.
     */
    function symbol() public view virtual override returns (string memory) {
        return _symbol;
    }

    /**
     * @dev Returns the number of decimals used to get its user representation.
     * For example, if `decimals` equals `2`, a balance of `505` tokens should
     * be displayed to a user as `5.05` (`505 / 10 ** 2`).
     *
     * Tokens usually opt for a value of 18, imitating the relationship between
     * Ether and Wei. This is the value {ERC20} uses, unless this function is
     * overridden;
     *
     * NOTE: This information is only used for _display_ purposes: it in
     * no way affects any of the arithmetic of the contract, including
     * {IERC20-balanceOf} and {IERC20-transfer}.
     */
    function decimals() public view virtual override returns (uint8) {
        return 18;
    }

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

    /**
     * @dev See {IERC20-balanceOf}.
     */
    function balanceOf(address account) public view virtual override returns (uint256) {
        return _balances[account];
    }

    /**
     * @dev See {IERC20-transfer}.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - the caller must have a balance of at least `amount`.
     */
    function transfer(address to, uint256 amount) public virtual override returns (bool) {
        address owner = _msgSender();
        _transfer(owner, to, amount);
        return true;
    }

    /**
     * @dev See {IERC20-allowance}.
     */
    function allowance(address owner, address spender) public view virtual override returns (uint256) {
        return _allowances[owner][spender];
    }

    /**
     * @dev See {IERC20-approve}.
     *
     * NOTE: If `amount` is the maximum `uint256`, the allowance is not updated on
     * `transferFrom`. This is semantically equivalent to an infinite approval.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function approve(address spender, uint256 amount) public virtual override returns (bool) {
        address owner = _msgSender();
        _approve(owner, spender, amount);
        return true;
    }

    /**
     * @dev See {IERC20-transferFrom}.
     *
     * Emits an {Approval} event indicating the updated allowance. This is not
     * required by the EIP. See the note at the beginning of {ERC20}.
     *
     * NOTE: Does not update the allowance if the current allowance
     * is the maximum `uint256`.
     *
     * Requirements:
     *
     * - `from` and `to` cannot be the zero address.
     * - `from` must have a balance of at least `amount`.
     * - the caller must have allowance for ``from``'s tokens of at least
     * `amount`.
     */
    function transferFrom(
        address from,
        address to,
        uint256 amount
    ) public virtual override returns (bool) {
        address spender = _msgSender();
        _spendAllowance(from, spender, amount);
        _transfer(from, to, amount);
        return true;
    }

    /**
     * @dev Atomically increases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) {
        address owner = _msgSender();
        _approve(owner, spender, allowance(owner, spender) + addedValue);
        return true;
    }

    /**
     * @dev Atomically decreases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     * - `spender` must have allowance for the caller of at least
     * `subtractedValue`.
     */
    function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) {
        address owner = _msgSender();
        uint256 currentAllowance = allowance(owner, spender);
        require(currentAllowance >= subtractedValue, "ERC20: decreased allowance below zero");
        unchecked {
            _approve(owner, spender, currentAllowance - subtractedValue);
        }

        return true;
    }

    /**
     * @dev Moves `amount` of tokens from `sender` to `recipient`.
     *
     * This internal function is equivalent to {transfer}, and can be used to
     * e.g. implement automatic token fees, slashing mechanisms, etc.
     *
     * Emits a {Transfer} event.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `from` must have a balance of at least `amount`.
     */
    function _transfer(
        address from,
        address to,
        uint256 amount
    ) internal virtual {
        require(from != address(0), "ERC20: transfer from the zero address");
        require(to != address(0), "ERC20: transfer to the zero address");

        _beforeTokenTransfer(from, to, amount);

        uint256 fromBalance = _balances[from];
        require(fromBalance >= amount, "ERC20: transfer amount exceeds balance");
        unchecked {
            _balances[from] = fromBalance - amount;
        }
        _balances[to] += amount;

        emit Transfer(from, to, amount);

        _afterTokenTransfer(from, to, amount);
    }

    /** @dev Creates `amount` tokens and assigns them to `account`, increasing
     * the total supply.
     *
     * Emits a {Transfer} event with `from` set to the zero address.
     *
     * Requirements:
     *
     * - `account` cannot be the zero address.
     */
    function _mint(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: mint to the zero address");

        _beforeTokenTransfer(address(0), account, amount);

        _totalSupply += amount;
        _balances[account] += amount;
        emit Transfer(address(0), account, amount);

        _afterTokenTransfer(address(0), account, amount);
    }

    /**
     * @dev Destroys `amount` tokens from `account`, reducing the
     * total supply.
     *
     * Emits a {Transfer} event with `to` set to the zero address.
     *
     * Requirements:
     *
     * - `account` cannot be the zero address.
     * - `account` must have at least `amount` tokens.
     */
    function _burn(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: burn from the zero address");

        _beforeTokenTransfer(account, address(0), amount);

        uint256 accountBalance = _balances[account];
        require(accountBalance >= amount, "ERC20: burn amount exceeds balance");
        unchecked {
            _balances[account] = accountBalance - amount;
        }
        _totalSupply -= amount;

        emit Transfer(account, address(0), amount);

        _afterTokenTransfer(account, address(0), amount);
    }

    /**
     * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens.
     *
     * This internal function is equivalent to `approve`, and can be used to
     * e.g. set automatic allowances for certain subsystems, etc.
     *
     * Emits an {Approval} event.
     *
     * Requirements:
     *
     * - `owner` cannot be the zero address.
     * - `spender` cannot be the zero address.
     */
    function _approve(
        address owner,
        address spender,
        uint256 amount
    ) internal virtual {
        require(owner != address(0), "ERC20: approve from the zero address");
        require(spender != address(0), "ERC20: approve to the zero address");

        _allowances[owner][spender] = amount;
        emit Approval(owner, spender, amount);
    }

    /**
     * @dev Updates `owner` s allowance for `spender` based on spent `amount`.
     *
     * Does not update the allowance amount in case of infinite allowance.
     * Revert if not enough allowance is available.
     *
     * Might emit an {Approval} event.
     */
    function _spendAllowance(
        address owner,
        address spender,
        uint256 amount
    ) internal virtual {
        uint256 currentAllowance = allowance(owner, spender);
        if (currentAllowance != type(uint256).max) {
            require(currentAllowance >= amount, "ERC20: insufficient allowance");
            unchecked {
                _approve(owner, spender, currentAllowance - amount);
            }
        }
    }

    /**
     * @dev Hook that is called before any transfer of tokens. This includes
     * minting and burning.
     *
     * Calling conditions:
     *
     * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens
     * will be transferred to `to`.
     * - when `from` is zero, `amount` tokens will be minted for `to`.
     * - when `to` is zero, `amount` of ``from``'s tokens 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 amount
    ) internal virtual {}

    /**
     * @dev Hook that is called after any transfer of tokens. This includes
     * minting and burning.
     *
     * Calling conditions:
     *
     * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens
     * has been transferred to `to`.
     * - when `from` is zero, `amount` tokens have been minted for `to`.
     * - when `to` is zero, `amount` of ``from``'s tokens have been 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 _afterTokenTransfer(
        address from,
        address to,
        uint256 amount
    ) internal virtual {}
}

File 4 of 11 : Ownable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (access/Ownable.sol)

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() {
        _transferOwnership(_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 {
        _transferOwnership(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");
        _transferOwnership(newOwner);
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Internal function without access restriction.
     */
    function _transferOwnership(address newOwner) internal virtual {
        address oldOwner = _owner;
        _owner = newOwner;
        emit OwnershipTransferred(oldOwner, newOwner);
    }
}

File 5 of 11 : SafeMath.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (utils/math/SafeMath.sol)

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 generally not needed starting with Solidity 0.8, since 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 subtraction 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 6 of 11 : Pausable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (security/Pausable.sol)

pragma solidity ^0.8.0;

import "../utils/Context.sol";

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

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

    bool private _paused;

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

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

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

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

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

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

File 7 of 11 : VintageWine.sol
// Pizza Token
//SPDX-License-Identifier: Unlicense
pragma solidity ^0.8.4;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/access/Ownable.sol";

contract VintageWine is ERC20("Vintage", "VINTAGE"), Ownable {
    uint256 public constant ONE_VINTAGEWINE = 1e18;
    uint256 public constant NUM_PROMOTIONAL_VINTAGEWINE = 500_000;
    uint256 public constant NUM_VINTAGEWINE_USDC_LP = 50_000_000;

    uint256 public NUM_VINTAGEWINE_AVAX_LP = 30_000_000;

    address public cellarAddress;
    address public wineryAddress;
    // address public vintnerAddress;
    address public upgradeAddress;

    bool public promotionalVintageWineMinted = false;
    bool public avaxLPVintageWineMinted = false;
    bool public USDCLPVintageWineMinted = false;

    // ADMIN

    /**
     * winery yields vintageWine
     */
    function setWineryAddress(address _wineryAddress) external onlyOwner {
        wineryAddress = _wineryAddress;
    }

    function setCellarAddress(address _cellarAddress) external onlyOwner {
        cellarAddress = _cellarAddress;
    }

    function setUpgradeAddress(address _upgradeAddress) external onlyOwner {
        upgradeAddress = _upgradeAddress;
    }

    /**
     * vintner consumes vintageWine
     * vintner address can only be set once
     */
    // function setVintnerAddress(address _vintnerAddress) external onlyOwner {
    //     require(
    //         address(vintnerAddress) == address(0),
    //         "vintner address already set"
    //     );
    //     vintnerAddress = _vintnerAddress;
    // }

    function mintVintageWine(address _to, uint256 amount) external onlyOwner {
        _mint(_to, amount);
    }

    function mintPromotionalVintageWine(address _to) external onlyOwner {
        require(
            !promotionalVintageWineMinted,
            "promotional vintageWine has already been minted"
        );
        promotionalVintageWineMinted = true;
        _mint(_to, NUM_PROMOTIONAL_VINTAGEWINE * ONE_VINTAGEWINE);
    }

    function mintAvaxLPVintageWine() external onlyOwner {
        require(
            !avaxLPVintageWineMinted,
            "avax vintageWine LP has already been minted"
        );
        avaxLPVintageWineMinted = true;
        _mint(owner(), NUM_VINTAGEWINE_AVAX_LP * ONE_VINTAGEWINE);
    }

    function mintUSDCLPVintageWine() external onlyOwner {
        require(
            !USDCLPVintageWineMinted,
            "USDC vintageWine LP has already been minted"
        );
        USDCLPVintageWineMinted = true;
        _mint(owner(), NUM_VINTAGEWINE_USDC_LP * ONE_VINTAGEWINE);
    }

    function setNumVintageWineAvaxLp(uint256 _numVintageWineAvaxLp)
        external
        onlyOwner
    {
        NUM_VINTAGEWINE_AVAX_LP = _numVintageWineAvaxLp;
    }

    // external

    function mint(address _to, uint256 _amount) external {
        require(
            wineryAddress != address(0) &&
                // vintnerAddress != address(0) &&
                cellarAddress != address(0) &&
                upgradeAddress != address(0),
            "missing initial requirements"
        );
        require(
            _msgSender() == wineryAddress || _msgSender() == owner(),
            "msgsender does not have permission"
        );
        _mint(_to, _amount);
    }

    function burn(address _from, uint256 _amount) external {
        require(
            // vintnerAddress != address(0) &&
            cellarAddress != address(0) && upgradeAddress != address(0),
            "missing initial requirements"
        );
        require(
            // _msgSender() == vintnerAddress ||
            _msgSender() == cellarAddress || _msgSender() == upgradeAddress,
            "msgsender does not have permission"
        );
        _burn(_from, _amount);
    }

    function transferToCellar(address _from, uint256 _amount) external {
        require(cellarAddress != address(0), "missing initial requirements");
        require(
            _msgSender() == cellarAddress,
            "only the cellar contract can call transferToCellar"
        );
        _transfer(_from, cellarAddress, _amount);
    }

    function transferForUpgradesFees(address _from, uint256 _amount) external {
        require(upgradeAddress != address(0), "missing initial requirements");
        require(
            _msgSender() == upgradeAddress,
            "only the upgrade contract can call transferForUpgradesFees"
        );
        _transfer(_from, upgradeAddress, _amount);
    }
}

File 8 of 11 : IERC20.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol)

pragma solidity ^0.8.0;

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

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

    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns the amount of tokens owned by `account`.
     */
    function balanceOf(address account) external view returns (uint256);

    /**
     * @dev Moves `amount` tokens from the caller's account to `to`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address to, uint256 amount) external returns (bool);

    /**
     * @dev Returns the remaining number of tokens that `spender` will be
     * allowed to spend on behalf of `owner` through {transferFrom}. This is
     * zero by default.
     *
     * This value changes when {approve} or {transferFrom} are called.
     */
    function allowance(address owner, address spender) external view returns (uint256);

    /**
     * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * IMPORTANT: Beware that changing an allowance with this method brings the risk
     * that someone may use both the old and the new allowance by unfortunate
     * transaction ordering. One possible solution to mitigate this race
     * condition is to first reduce the spender's allowance to 0 and set the
     * desired value afterwards:
     * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
     *
     * Emits an {Approval} event.
     */
    function approve(address spender, uint256 amount) external returns (bool);

    /**
     * @dev Moves `amount` tokens from `from` to `to` using the
     * allowance mechanism. `amount` is then deducted from the caller's
     * allowance.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(
        address from,
        address to,
        uint256 amount
    ) external returns (bool);
}

File 9 of 11 : Address.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (utils/Address.sol)

pragma solidity ^0.8.1;

/**
 * @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
     * ====
     *
     * [IMPORTANT]
     * ====
     * You shouldn't rely on `isContract` to protect against flash loan attacks!
     *
     * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets
     * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract
     * constructor.
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize/address.code.length, which returns 0
        // for contracts in construction, since the code is only stored at the end
        // of the constructor execution.

        return account.code.length > 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 11 : IERC20Metadata.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/IERC20Metadata.sol)

pragma solidity ^0.8.0;

import "../IERC20.sol";

/**
 * @dev Interface for the optional metadata functions from the ERC20 standard.
 *
 * _Available since v4.1._
 */
interface IERC20Metadata is IERC20 {
    /**
     * @dev Returns the name of the token.
     */
    function name() external view returns (string memory);

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

    /**
     * @dev Returns the decimals places of the token.
     */
    function decimals() external view returns (uint8);
}

File 11 of 11 : Context.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)

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

Settings
{
  "optimizer": {
    "enabled": true,
    "runs": 100
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "libraries": {}
}

Contract ABI

[{"inputs":[{"internalType":"contract VintageWine","name":"_vintageWine","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","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"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"inputs":[],"name":"DELAYED_UNSTAKE_BURN_PERCENT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DELAYED_UNSTAKE_LOCKUP_PERIOD","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"QUICK_UNSTAKE_BURN_PERCENT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"QUICK_UNSTAKE_CONTRIBUTION_PERCENT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"claimDelayedUnstake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"frozenVintageWine","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","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":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_share","type":"uint256"}],"name":"prepareDelayedUnstake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_share","type":"uint256"}],"name":"quickUnstake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_startTime","type":"uint256"}],"name":"setStakeStartTime","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"stake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stakeStarted","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stakeTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"unlockAmounts","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"unlockTimestamps","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"vintageWine","outputs":[{"internalType":"contract VintageWine","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"vintageWineBalance","outputs":[{"internalType":"uint256","name":"balance","type":"uint256"}],"stateMutability":"view","type":"function"}]

60806040523480156200001157600080fd5b5060405162001a9638038062001a968339810160408190526200003491620001ec565b604080518082018252600e81526d5374616b65642056696e7461676560901b6020808301918252835180850190945260088452675356494e5441474560c01b9084015281519192916200008a9160039162000146565b508051620000a090600490602084019062000146565b505050620000bd620000b7620000f060201b60201c565b620000f4565b6005805460ff60a01b19169055600680546001600160a01b0319166001600160a01b03929092169190911790556200025b565b3390565b600580546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b82805462000154906200021e565b90600052602060002090601f016020900481019282620001785760008555620001c3565b82601f106200019357805160ff1916838001178555620001c3565b82800160010185558215620001c3579182015b82811115620001c3578251825591602001919060010190620001a6565b50620001d1929150620001d5565b5090565b5b80821115620001d15760008155600101620001d6565b600060208284031215620001ff57600080fd5b81516001600160a01b03811681146200021757600080fd5b9392505050565b600181811c908216806200023357607f821691505b602082108114156200025557634e487b7160e01b600052602260045260246000fd5b50919050565b61182b806200026b6000396000f3fe608060405234801561001057600080fd5b50600436106101a55760003560e01c806395d89b41116100ef578063c55510a011610092578063c55510a014610350578063cc1b63d514610359578063dbc782311461036c578063dd62ed3e14610374578063edb46a1b14610387578063efe6066f1461039a578063f2fde38b146103ad578063fc2759bf146103c057600080fd5b806395d89b41146102ee578063a457c2d7146102f6578063a694fc3a14610309578063a8c43c7c1461031c578063a9059cbb14610324578063b31c67fa14610337578063b77a2c1c1461033f578063bb09ae991461034857600080fd5b806347ef867e1161015757806347ef867e1461023a5780634c7cc901146102655780635c975abb1461026f578063634b189714610277578063700763291461028c57806370a08231146102ac578063715018a6146102d55780638da5cb5b146102dd57600080fd5b8063058b7784146101aa57806306fdde03146101c5578063095ea7b3146101da57806318160ddd146101fd57806323b872dd14610205578063313ce567146102185780633950935114610227575b600080fd5b6101b2600a81565b6040519081526020015b60405180910390f35b6101cd6103e0565b6040516101bc9190611529565b6101ed6101e8366004611578565b610472565b60405190151581526020016101bc565b6002546101b2565b6101ed6102133660046115a2565b61048a565b604051601281526020016101bc565b6101ed610235366004611578565b6104b0565b60065461024d906001600160a01b031681565b6040516001600160a01b0390911681526020016101bc565b6101b26202a30081565b6101ed6104d2565b61028a6102853660046115de565b6104e2565b005b6101b261029a3660046115f7565b60096020526000908152604090205481565b6101b26102ba3660046115f7565b6001600160a01b031660009081526020819052604090205490565b61028a610615565b6005546001600160a01b031661024d565b6101cd61064b565b6101ed610304366004611578565b61065a565b61028a6103173660046115de565b6106e0565b6101b2603281565b6101ed610332366004611578565b61080d565b6101b2601981565b6101b2600a5481565b6101b261081b565b6101b260075481565b61028a6103673660046115de565b61089b565b6101ed610969565b6101b2610382366004611612565b610983565b61028a6103953660046115de565b6109ae565b61028a6103a83660046115de565b610ae3565b61028a6103bb3660046115f7565b610bd8565b6101b26103ce3660046115f7565b60086020526000908152604090205481565b6060600380546103ef90611645565b80601f016020809104026020016040519081016040528092919081815260200182805461041b90611645565b80156104685780601f1061043d57610100808354040283529160200191610468565b820191906000526020600020905b81548152906001019060200180831161044b57829003601f168201915b5050505050905090565b600033610480818585610c70565b5060019392505050565b600033610498858285610d95565b6104a3858585610e09565b60019150505b9392505050565b6000336104808185856104c38383610983565b6104cd9190611696565b610c70565b600554600160a01b900460ff1690565b6104ea6104d2565b156105105760405162461bcd60e51b8152600401610507906116ae565b60405180910390fd5b600061051b82610fc5565b90506105273383610fe9565b600061053f606461053984600a611122565b9061112e565b905061054b81836116d8565b3360009081526008602052604081208054929450849290919061056f908490611696565b9091555061058290506202a30042611696565b33600090815260096020526040812091909155600780548492906105a7908490611696565b9091555050600654604051632770a7eb60e21b81526001600160a01b0390911690639dc29fac906105de90309085906004016116ef565b600060405180830381600087803b1580156105f857600080fd5b505af115801561060c573d6000803e3d6000fd5b50505050505050565b6005546001600160a01b0316331461063f5760405162461bcd60e51b815260040161050790611708565b610649600061113a565b565b6060600480546103ef90611645565b600033816106688286610983565b9050838110156106c85760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b6064820152608401610507565b6106d58286868403610c70565b506001949350505050565b6106e86104d2565b156107055760405162461bcd60e51b8152600401610507906116ae565b61070d610969565b61074f5760405162461bcd60e51b8152602060048201526013602482015272165bdd4818d85b89dd081cdd185ad9481e595d606a1b6044820152606401610507565b600061075a60025490565b905080158061076e575061076c61081b565b155b156107825761077d338361118c565b6107a7565b600061079961078f61081b565b6105398585611122565b90506107a5338261118c565b505b6006546001600160a01b031663ca39ec5133846040518363ffffffff1660e01b81526004016107d79291906116ef565b600060405180830381600087803b1580156107f157600080fd5b505af1158015610805573d6000803e3d6000fd5b505050505050565b600033610480818585610e09565b6007546006546040516370a0823160e01b8152306004820152600092916001600160a01b0316906370a0823190602401602060405180830381865afa158015610868573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061088c919061173d565b61089691906116d8565b905090565b6005546001600160a01b031633146108c55760405162461bcd60e51b815260040161050790611708565b428110156109155760405162461bcd60e51b815260206004820152601f60248201527f737461727454696d652063616e6e6f7420626520696e207468652070617374006044820152606401610507565b61091d610969565b156109645760405162461bcd60e51b81526020600482015260176024820152761cdd185ada5b99c8185b1c9958591e481cdd185c9d1959604a1b6044820152606401610507565b600a55565b6000600a54600014158015610896575050600a5442101590565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b6109b66104d2565b156109d35760405162461bcd60e51b8152600401610507906116ae565b33600090815260096020526040902054421015610a2d5760405162461bcd60e51b8152602060048201526018602482015277159253951051d1481b9bdd081e595d081d5b9b1bd8dad95960421b6044820152606401610507565b33600090815260086020526040902054811115610a8c5760405162461bcd60e51b815260206004820152601b60248201527f696e73756666696369656e74206c6f636b65642062616c616e636500000000006044820152606401610507565b3360009081526008602052604081208054839290610aab9084906116d8565b925050819055508060076000828254610ac491906116d8565b9091555050600654610ae0906001600160a01b03163383611259565b50565b610aeb6104d2565b15610b085760405162461bcd60e51b8152600401610507906116ae565b6000610b1382610fc5565b90506000610b316064610539610b2a6032836116d8565b8590611122565b90506000610b456064610539856019611122565b9050610b513385610fe9565b600654604051632770a7eb60e21b81526001600160a01b0390911690639dc29fac90610b8390309085906004016116ef565b600060405180830381600087803b158015610b9d57600080fd5b505af1158015610bb1573d6000803e3d6000fd5b50505050610bd2610bbf3390565b6006546001600160a01b03169084611259565b50505050565b6005546001600160a01b03163314610c025760405162461bcd60e51b815260040161050790611708565b6001600160a01b038116610c675760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610507565b610ae08161113a565b6001600160a01b038316610cd25760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610507565b6001600160a01b038216610d335760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610507565b6001600160a01b0383811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b6000610da18484610983565b90506000198114610bd25781811015610dfc5760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610507565b610bd28484848403610c70565b6001600160a01b038316610e6d5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610507565b6001600160a01b038216610ecf5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610507565b6001600160a01b03831660009081526020819052604090205481811015610f475760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b6064820152608401610507565b6001600160a01b03808516600090815260208190526040808220858503905591851681529081208054849290610f7e908490611696565b92505081905550826001600160a01b0316846001600160a01b03166000805160206117d683398151915284604051610fb891815260200190565b60405180910390a3610bd2565b600080610fd160025490565b90506104a981610539610fe261081b565b8690611122565b6001600160a01b0382166110495760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b6064820152608401610507565b6001600160a01b038216600090815260208190526040902054818110156110bd5760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b6064820152608401610507565b6001600160a01b03831660009081526020819052604081208383039055600280548492906110ec9084906116d8565b90915550506040518281526000906001600160a01b038516906000805160206117d683398151915290602001610d88565b505050565b60006104a98284611756565b60006104a98284611775565b600580546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6001600160a01b0382166111e25760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610507565b80600260008282546111f49190611696565b90915550506001600160a01b03821660009081526020819052604081208054839290611221908490611696565b90915550506040518181526001600160a01b038316906000906000805160206117d68339815191529060200160405180910390a35050565b61111d8363a9059cbb60e01b84846040516024016112789291906116ef565b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b03199093169290921790915260006112ff826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b031661137c9092919063ffffffff16565b80519091501561111d578080602001905181019061131d9190611797565b61111d5760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610507565b606061138b8484600085611393565b949350505050565b6060824710156113f45760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b6064820152608401610507565b6001600160a01b0385163b61144b5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610507565b600080866001600160a01b0316858760405161146791906117b9565b60006040518083038185875af1925050503d80600081146114a4576040519150601f19603f3d011682016040523d82523d6000602084013e6114a9565b606091505b50915091506114b98282866114c4565b979650505050505050565b606083156114d35750816104a9565b8251156114e35782518084602001fd5b8160405162461bcd60e51b81526004016105079190611529565b60005b83811015611518578181015183820152602001611500565b83811115610bd25750506000910152565b60208152600082518060208401526115488160408501602087016114fd565b601f01601f19169190910160400192915050565b80356001600160a01b038116811461157357600080fd5b919050565b6000806040838503121561158b57600080fd5b6115948361155c565b946020939093013593505050565b6000806000606084860312156115b757600080fd5b6115c08461155c565b92506115ce6020850161155c565b9150604084013590509250925092565b6000602082840312156115f057600080fd5b5035919050565b60006020828403121561160957600080fd5b6104a98261155c565b6000806040838503121561162557600080fd5b61162e8361155c565b915061163c6020840161155c565b90509250929050565b600181811c9082168061165957607f821691505b6020821081141561167a57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b600082198211156116a9576116a9611680565b500190565b60208082526010908201526f14185d5cd8589b194e881c185d5cd95960821b604082015260600190565b6000828210156116ea576116ea611680565b500390565b6001600160a01b03929092168252602082015260400190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60006020828403121561174f57600080fd5b5051919050565b600081600019048311821515161561177057611770611680565b500290565b60008261179257634e487b7160e01b600052601260045260246000fd5b500490565b6000602082840312156117a957600080fd5b815180151581146104a957600080fd5b600082516117cb8184602087016114fd565b919091019291505056feddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220656295aeb10a8f4ec3948c8a3af44f86ad395aed3e7e24bea3497117bc50e6e564736f6c634300080b003300000000000000000000000001af64ef39aeb5612202aa07b3a3829f20c395fd

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

00000000000000000000000001af64ef39aeb5612202aa07b3a3829f20c395fd

-----Decoded View---------------
Arg [0] : _vintageWine (address): 0x01af64ef39aeb5612202aa07b3a3829f20c395fd

-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 00000000000000000000000001af64ef39aeb5612202aa07b3a3829f20c395fd


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