Contract 0x63c0cf90ae12190b388f9914531369ac1e4e4e47

Contract Overview

Balance:
0 AVAX

AVAX Value:
$0.00

Token:
Txn Hash Method
Block
From
To
Value [Txn Fee]
0xa1f33395c2ebf858d445692aba0ab1dcf131a1d436abe202283ad5f5b3dc21aaConvert Multiple165159302022-06-25 22:11:2323 hrs 6 mins ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.014040027 27.000000001
0x23bf7c7d07137f5723dd9e26bf7cf4b4f179ffa4a56e207a71428e21d7acb3bcConvert Multiple164736052022-06-24 22:40:101 day 22 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.020402361 27.000000001
0xbbfb6bc9729a8e6698bb6e7f859c788fd6e04b44cdfb0994b0e024da4f93fdf4Convert Multiple164290742022-06-23 21:59:032 days 23 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.022731759 27.000000001
0xc9d2a76e5f3a57ca5190ffb99f5b490c53fb0a00605ea7edfa09533ef50d563eConvert Multiple163858542022-06-22 21:57:583 days 23 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.007412202 27.000000001
0x254d78f44bf5fa5d71eca78c884036197bd4d74da4261c4cead9b392df63a359Convert Multiple163450372022-06-21 23:18:184 days 21 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.020677923 27.000000001
0xa7730b3cda0839bfae15f9daac3de427c871db3c0cd4aa6641a8debb9e116325Convert Multiple163018702022-06-20 23:17:335 days 21 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.027039528001 27.000000001
0xa1d3199de2970c5cdd7ef05a373d9ca758d476666b4652856163239abc88622eConvert Multiple162581842022-06-19 23:02:316 days 22 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.020398257 27.000000001
0xa149ae4425cb923057b93c7ad9ed58afbcc4e9d8973423c727727c381dc6f541Convert Multiple162116642022-06-18 21:25:587 days 23 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.022985026472 32.008604048
0x473f3b0b131d96bbd938ad4536ab04235d4170104c5868ec0a87b227be7d5e89Convert Multiple161716462022-06-17 23:25:068 days 21 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.009070704 27.000000001
0xd5d21f1c0ffb612280bfea38af4a4f1b30f2788d5a6a176ebe78a2d5ad8f00efConvert Multiple161264652022-06-16 22:22:069 days 22 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.059391468002 27.000000001
0x7b965fb18b9f31876d5fe91ba56affc022eebcecbc61fdf7809b9a3dd2cdf624Convert Multiple160388802022-06-14 22:16:5611 days 23 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.033489531001 27.000000001
0x98e89371ccf0f78fa08c0f2dbcd33a894d25e6e20e9484bb9408f98450440abfConvert Multiple159950932022-06-13 22:23:4912 days 22 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.046008999001 27.000000001
0xaa74ef0665a4651312a4deef1a18d7b1f0cf565cdd9063755ca216dfafb92682Convert Multiple159524372022-06-12 23:28:0713 days 21 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.026865189 27.000000001
0x7977d735d43c0d4e61318e1c706542a5ff751045769846355086258d63d45133Convert Multiple159099152022-06-11 23:59:4314 days 21 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.027265518001 27.000000001
0x38257eba4af7ba57b1ff823a9aa943dbb4616502442454bbcce056fa1f78bb55Convert Multiple158617552022-06-10 21:13:1516 days 4 mins ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.007412202 27.000000001
0xaf0cc15b04c87584ef9246fa19f9fb57f968398b98c93137c4fd0d2faf51a058Convert Multiple158204262022-06-09 22:11:1116 days 23 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.015642693 27.000000001
0x5af5c7eff9b2b21d998e56561149cf04ee6b128bcd6bcedef9a4193a14def50dConvert Multiple157785832022-06-08 22:47:3017 days 22 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.013876137 27.000000001
0x2ea2257b5dbf7a03b997bc9ec554dbe96075ab627ffccfb46c0cb33d6638f444Convert Multiple157334672022-06-07 21:41:2218 days 23 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.027330858001 27.000000001
0x2ec66ea0cf1d80c8dfc092debdb972258ca64fccd0364ed722c6b8b5540e3ebdConvert Multiple156959022022-06-07 0:46:1419 days 20 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.02681586 27.000000001
0x4512bd6ff1d08d7e7f609dab8e0b4d59fdaa3748d21e4388b187a89f10416791Convert Multiple156469512022-06-05 21:02:4021 days 14 mins ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.007412202 27.000000001
0x2ba921c262d9881b218f0ded93086f683ce8ca96da44b7d2ebfa162df6cedf98Convert Multiple156049032022-06-04 21:32:1921 days 23 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.00897885 27.000000001
0xe57e5e985541c1f492f7de8ff3d2d63f24778f0408c47d504c4f47a28fdcf840Convert Multiple155619712022-06-03 21:33:3622 days 23 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.007412202 27.000000001
0x45e3d9c7c76dd4ddcb72cba8f6c09d82c428dc8c08b009e31601babf1994165bConvert Multiple155186032022-06-02 21:23:2723 days 23 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.027318384001 27.000000001
0x2aae66731706900f483ad91f9b482db06696284db08f6338fa91b242bf20b730Convert Multiple154802362022-06-01 23:59:1124 days 21 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.026068365 27.000000001
0xa245f5f7af031aaf5b1fe75c54e36aa4057d52fa1dd7b60351ccc5a51ec39d1fConvert Multiple154326182022-05-31 21:29:2925 days 23 hrs ago0x65a8cbbf9bc23bcb1c9d1d3039b5bbd9101e6b7a IN  0x63c0cf90ae12190b388f9914531369ac1e4e4e470 AVAX0.020393073 27.000000001
[ Download CSV Export 
Parent Txn Hash Block From To Value
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
MoneyMaker

Compiler Version
v0.6.12+commit.27d51765

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion

Contract Source Code (Solidity Standard Json-Input format)

File 1 of 12 : MoneyMaker.sol
// SPDX-License-Identifier: MIT

// P1 - P3: OK
pragma solidity 0.6.12;

import "./libraries/SafeMath.sol";
import "./libraries/SafeERC20.sol";

import "./traderjoe/interfaces/IERC20.sol";
import "./traderjoe/interfaces/IJoePair.sol";
import "./traderjoe/interfaces/IJoeFactory.sol";
import "./traderjoe/libraries/JoeLibrary.sol";

import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/utils/EnumerableSet.sol";

/// @title Money Maker
/// @author Trader Joe
/// @notice MoneyMaker receives 0.05% of the swaps done on Trader Joe in the form of an LP. It swaps those LPs
/// to a token of choice and sends it to the JoeBar
contract MoneyMaker is Ownable {
    using EnumerableSet for EnumerableSet.AddressSet;
    using SafeERC20 for IERC20;
    using SafeMath for uint256;

    IJoeFactory public immutable factory;

    address public immutable bar;
    address private immutable wavax;
    /// @notice Any ERC20
    address public tokenTo;
    /// @notice In basis points aka parts per 10,000 so 5000 is 50%, cap of 50%, default is 0
    uint256 public devCut = 0;
    address public devAddr;

    // @notice Set of addresses that can perform certain functions
    EnumerableSet.AddressSet private _isAuth;

    modifier onlyAuth() {
        require(_isAuth.contains(_msgSender()), "MoneyMaker: FORBIDDEN");
        _;
    }

    /// @dev Maps a token `token` to another token `bridge` so that it uses `token/bridge` pair to convert token
    mapping(address => address) internal _bridges;

    event AddAuthorizedAddress(address indexed _addr);
    event RemoveAuthorizedAddress(address indexed _addr);
    event SetDevAddr(address _addr);
    event SetDevCut(uint256 _amount);
    event SetTokenTo(address _tokenTo);
    event LogBridgeSet(address indexed token, address indexed oldBridge, address indexed bridge);
    event LogConvert(
        address indexed server,
        address indexed token0,
        address indexed token1,
        uint256 amount0,
        uint256 amount1,
        uint256 amountTOKEN
    );

    /// @notice Constructor
    /// @param _factory The address of JoeFactory
    /// @param _bar The address of JoeBar
    /// @param _tokenTo The address of the token we want to convert to
    /// @param _wavax The address of wavax
    constructor(
        address _factory,
        address _bar,
        address _tokenTo,
        address _wavax
    ) public {
        require(_factory != address(0), "MoneyMaker: factory can't be address(0)");
        require(_bar != address(0), "MoneyMaker: bar can't be address(0)");
        require(_tokenTo != address(0), "MoneyMaker: token can't be address(0)");
        require(_wavax != address(0), "MoneyMaker: wavax can't be address(0)");
        factory = IJoeFactory(_factory);
        bar = _bar;
        tokenTo = _tokenTo;
        wavax = _wavax;
        devAddr = _msgSender();
        _isAuth.add(_msgSender());
    }

    /// @notice Adds a user to the authorized addresses
    /// @param _auth The address to add
    function addAuth(address _auth) external onlyOwner {
        require(_isAuth.add(_auth), "MoneyMaker: Address is already authorized");
        emit AddAuthorizedAddress(_auth);
    }

    /// @notice Remove a user of authorized addresses
    /// @param _auth The address to remove
    function removeAuth(address _auth) external onlyOwner {
        require(_isAuth.remove(_auth), "MoneyMaker: Address is not authorized");
        emit RemoveAuthorizedAddress(_auth);
    }

    /// @notice Return the list of authorized addresses
    /// @param index Index of the returned address
    /// @return The authorized address at `index`
    function getAuth(uint256 index) external view returns (address) {
        return _isAuth.at(index);
    }

    /// @notice Return the length of authorized addresses
    /// @return The number of authorized addresses
    function lenAuth() external view returns (uint256) {
        return _isAuth.length();
    }

    /// @notice Force using `pair/bridge` pair to convert `token`
    /// @param token The address of the tokenFrom
    /// @param bridge The address of the tokenTo
    function setBridge(address token, address bridge) external onlyAuth {
        // Checks
        require(token != tokenTo && token != wavax && token != bridge, "MoneyMaker: Invalid bridge");

        // Effects
        address oldBridge = _bridges[token];
        _bridges[token] = bridge;
        emit LogBridgeSet(token, oldBridge, bridge);
    }

    /// @notice Sets dev cut, which will be sent to `devAddr`, can't be greater than 50%
    /// @param _amount The new devCut value
    function setDevCut(uint256 _amount) external onlyOwner {
        require(_amount <= 5000, "setDevCut: cut too high");
        devCut = _amount;

        emit SetDevCut(_amount);
    }

    /// @notice Sets `devAddr`, the address that will receive the `devCut`
    /// @param _addr The new dev address
    function setDevAddr(address _addr) external onlyOwner {
        require(_addr != address(0), "setDevAddr, address cannot be zero address");
        devAddr = _addr;

        emit SetDevAddr(_addr);
    }

    /// @notice Sets token that we're buying back
    /// @param _tokenTo The new token address
    function setTokenToAddress(address _tokenTo) external onlyOwner {
        require(_tokenTo != address(0), "setTokenToAddress, address cannot be zero address");
        tokenTo = _tokenTo;

        emit SetTokenTo(_tokenTo);
    }

    /// @notice Returns the `bridge` of a `token`
    /// @param token The tokenFrom address
    /// @return bridge The tokenTo address
    function bridgeFor(address token) public view returns (address bridge) {
        bridge = _bridges[token];
        if (bridge == address(0)) {
            bridge = wavax;
        }
    }

    // C6: It's not a fool proof solution, but it prevents flash loans, so here it's ok to use tx.origin
    modifier onlyEOA() {
        // Try to make flash-loan exploit harder to do by only allowing externally owned addresses.
        require(_msgSender() == tx.origin, "MoneyMaker: must use EOA");
        _;
    }

    /// @notice Converts a pair of tokens to tokenTo
    /// @dev _convert is separate to save gas by only checking the 'onlyEOA' modifier once in case of convertMultiple
    /// @param token0 The address of the first token of the pair that will be converted
    /// @param token1 The address of the second token of the pair that will be converted
    /// @param slippage The accepted slippage, in basis points aka parts per 10,000 so 5000 is 50%
    function convert(
        address token0,
        address token1,
        uint256 slippage
    ) external onlyEOA onlyAuth {
        require(slippage < 5_000, "MoneyMaker: slippage needs to be lower than 50%");
        _convert(token0, token1, slippage);
    }

    /// @notice Converts a list of pairs of tokens to tokenTo
    /// @dev _convert is separate to save gas by only checking the 'onlyEOA' modifier once in case of convertMultiple
    /// @param token0 The list of addresses of the first token of the pairs that will be converted
    /// @param token1 The list of addresses of the second token of the pairs that will be converted
    /// @param slippage The accepted slippage, in basis points aka parts per 10,000 so 5000 is 50%
    function convertMultiple(
        address[] calldata token0,
        address[] calldata token1,
        uint256 slippage
    ) external onlyEOA onlyAuth {
        // TODO: This can be optimized a fair bit, but this is safer and simpler for now
        require(slippage < 5_000, "MoneyMaker: slippage needs to be lower than 50%");
        require(token0.length == token1.length, "MoneyMaker: arrays length don't match");

        uint256 len = token0.length;
        for (uint256 i = 0; i < len; i++) {
            _convert(token0[i], token1[i], slippage);
        }
    }

    /// @notice Converts a pair of tokens to tokenTo
    /// @dev _convert is separate to save gas by only checking the 'onlyEOA' modifier once in case of convertMultiple
    /// @param token0 The address of the first token of the pair that is currently being converted
    /// @param token1 The address of the second token of the pair that is currently being converted
    /// @param slippage The accepted slippage, in basis points aka parts per 10,000 so 5000 is 50%
    function _convert(
        address token0,
        address token1,
        uint256 slippage
    ) internal {
        uint256 amount0;
        uint256 amount1;

        // handle case where non-LP tokens need to be converted
        if (token0 == token1) {
            amount0 = IERC20(token0).balanceOf(address(this));
            amount1 = 0;
        } else {
            IJoePair pair = IJoePair(factory.getPair(token0, token1));
            require(address(pair) != address(0), "MoneyMaker: Invalid pair");

            IERC20(address(pair)).safeTransfer(address(pair), pair.balanceOf(address(this)));

            // take balance of tokens in this contract before burning the pair, incase there are already some here
            uint256 tok0bal = IERC20(token0).balanceOf(address(this));
            uint256 tok1bal = IERC20(token1).balanceOf(address(this));

            pair.burn(address(this));

            // subtract old balance of tokens from new balance
            // the return values of pair.burn cant be trusted due to transfer tax tokens
            amount0 = IERC20(token0).balanceOf(address(this)).sub(tok0bal);
            amount1 = IERC20(token1).balanceOf(address(this)).sub(tok1bal);
        }
        emit LogConvert(
            _msgSender(),
            token0,
            token1,
            amount0,
            amount1,
            _convertStep(token0, token1, amount0, amount1, slippage)
        );
    }

    /// @notice Used to convert two tokens to `tokenTo`, step by step, called recursively
    /// @param token0 The address of the first token
    /// @param token1 The address of the second token
    /// @param amount0 The amount of the `token0`
    /// @param amount1 The amount of the `token1`
    /// @param slippage The accepted slippage, in basis points aka parts per 10,000 so 5000 is 50%
    /// @return tokenOut The amount of token
    function _convertStep(
        address token0,
        address token1,
        uint256 amount0,
        uint256 amount1,
        uint256 slippage
    ) internal returns (uint256 tokenOut) {
        // Interactions
        if (token0 == token1) {
            uint256 amount = amount0.add(amount1);
            if (token0 == tokenTo) {
                IERC20(tokenTo).safeTransfer(bar, amount);
                tokenOut = amount;
            } else if (token0 == wavax) {
                tokenOut = _toToken(wavax, amount, slippage);
            } else {
                address bridge = bridgeFor(token0);
                amount = _swap(token0, bridge, amount, address(this), slippage);
                tokenOut = _convertStep(bridge, bridge, amount, 0, slippage);
            }
        } else if (token0 == tokenTo) {
            // eg. TOKEN - AVAX
            IERC20(tokenTo).safeTransfer(bar, amount0);
            tokenOut = _toToken(token1, amount1, slippage).add(amount0);
        } else if (token1 == tokenTo) {
            // eg. USDT - TOKEN
            IERC20(tokenTo).safeTransfer(bar, amount1);
            tokenOut = _toToken(token0, amount0, slippage).add(amount1);
        } else if (token0 == wavax) {
            // eg. AVAX - USDC
            tokenOut = _toToken(wavax, _swap(token1, wavax, amount1, address(this), slippage).add(amount0), slippage);
        } else if (token1 == wavax) {
            // eg. USDT - AVAX
            tokenOut = _toToken(wavax, _swap(token0, wavax, amount0, address(this), slippage).add(amount1), slippage);
        } else {
            // eg. MIC - USDT
            address bridge0 = bridgeFor(token0);
            address bridge1 = bridgeFor(token1);
            if (bridge0 == token1) {
                // eg. MIC - USDT - and bridgeFor(MIC) = USDT
                tokenOut = _convertStep(
                    bridge0,
                    token1,
                    _swap(token0, bridge0, amount0, address(this), slippage),
                    amount1,
                    slippage
                );
            } else if (bridge1 == token0) {
                // eg. WBTC - DSD - and bridgeFor(DSD) = WBTC
                tokenOut = _convertStep(
                    token0,
                    bridge1,
                    amount0,
                    _swap(token1, bridge1, amount1, address(this), slippage),
                    slippage
                );
            } else {
                tokenOut = _convertStep(
                    bridge0,
                    bridge1, // eg. USDT - DSD - and bridgeFor(DSD) = WBTC
                    _swap(token0, bridge0, amount0, address(this), slippage),
                    _swap(token1, bridge1, amount1, address(this), slippage),
                    slippage
                );
            }
        }
    }

    /// @notice Swaps `amountIn` `fromToken` to `toToken` and sends it to `to`, `amountOut` is required to be greater
    /// than allowed `slippage`
    /// @param fromToken The address of token that will be swapped
    /// @param toToken The address of the token that will be received
    /// @param amountIn The amount of the `fromToken`
    /// @param to The address that will receive the `toToken`
    /// @param slippage The accepted slippage, in basis points aka parts per 10,000 so 5000 is 50%
    /// @return amountOut The amount of `toToken` sent to `to`
    function _swap(
        address fromToken,
        address toToken,
        uint256 amountIn,
        address to,
        uint256 slippage
    ) internal returns (uint256 amountOut) {
        // Checks
        // X1 - X5: OK
        IJoePair pair = IJoePair(factory.getPair(fromToken, toToken));
        require(address(pair) != address(0), "MoneyMaker: Cannot convert");

        (uint256 reserve0, uint256 reserve1, ) = pair.getReserves();
        (uint256 reserveInput, uint256 reserveOutput) = fromToken == pair.token0()
            ? (reserve0, reserve1)
            : (reserve1, reserve0);
        IERC20(fromToken).safeTransfer(address(pair), amountIn);
        uint256 amountInput = IERC20(fromToken).balanceOf(address(pair)).sub(reserveInput); // calculate amount that was transferred, this accounts for transfer taxes

        amountOut = JoeLibrary.getAmountOut(amountInput, reserveInput, reserveOutput);

        {
            uint256 rest = uint256(10_000).sub(slippage);
            /// @dev We simulate the amount received if we did a swapIn and swapOut without updating the reserves,
            /// hence why we do rest^2, i.e. calculating the slippage twice cause we actually do two swaps.
            /// This allows us to catch if a pair has low liquidity
            require(
                JoeLibrary.getAmountOut(amountOut, reserveOutput, reserveInput) >=
                    amountInput.mul(rest).mul(rest).div(100_000_000),
                "MoneyMaker: Slippage caught"
            );
        }

        (uint256 amount0Out, uint256 amount1Out) = fromToken == pair.token0()
            ? (uint256(0), amountOut)
            : (amountOut, uint256(0));
        pair.swap(amount0Out, amount1Out, to, new bytes(0));
    }

    /// @notice Swaps an amount of token to another token, `tokenTo`
    /// @dev `amountOut` is required to be greater after slippage
    /// @param token The address of token that will be swapped
    /// @param amountIn The amount of the `token`
    /// @param slippage The accepted slippage, in basis points aka parts per 10,000 so 5000 is 50%
    /// @return amountOut The amount of `toToken` sent to JoeBar
    function _toToken(
        address token,
        uint256 amountIn,
        uint256 slippage
    ) internal returns (uint256 amountOut) {
        uint256 amount = amountIn;
        if (devCut > 0) {
            amount = amount.mul(devCut).div(10000);
            IERC20(token).safeTransfer(devAddr, amount);
            amount = amountIn.sub(amount);
        }
        amountOut = _swap(token, tokenTo, amount, bar, slippage);
    }
}

File 2 of 12 : SafeMath.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.6.12;

// a library for performing overflow-safe math, updated with awesomeness from of DappHub (https://github.com/dapphub/ds-math)
library SafeMath {
    function add(uint256 a, uint256 b) internal pure returns (uint256 c) {
        require((c = a + b) >= b, "SafeMath: Add Overflow");
    }

    function sub(uint256 a, uint256 b) internal pure returns (uint256 c) {
        require((c = a - b) <= a, "SafeMath: Underflow");
    }

    function mul(uint256 a, uint256 b) internal pure returns (uint256 c) {
        require(b == 0 || (c = a * b) / b == a, "SafeMath: Mul Overflow");
    }

    function div(uint256 a, uint256 b) internal pure returns (uint256 c) {
        require(b > 0, "SafeMath: Div by Zero");
        c = a / b;
    }

    function to128(uint256 a) internal pure returns (uint128 c) {
        require(a <= uint128(-1), "SafeMath: uint128 Overflow");
        c = uint128(a);
    }
}

library SafeMath128 {
    function add(uint128 a, uint128 b) internal pure returns (uint128 c) {
        require((c = a + b) >= b, "SafeMath: Add Overflow");
    }

    function sub(uint128 a, uint128 b) internal pure returns (uint128 c) {
        require((c = a - b) <= a, "SafeMath: Underflow");
    }
}

File 3 of 12 : SafeERC20.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.6.12;

import "../interfaces/IERC20.sol";

library SafeERC20 {
    function safeSymbol(IERC20 token) internal view returns (string memory) {
        (bool success, bytes memory data) = address(token).staticcall(abi.encodeWithSelector(0x95d89b41));
        return success && data.length > 0 ? abi.decode(data, (string)) : "???";
    }

    function safeName(IERC20 token) internal view returns (string memory) {
        (bool success, bytes memory data) = address(token).staticcall(abi.encodeWithSelector(0x06fdde03));
        return success && data.length > 0 ? abi.decode(data, (string)) : "???";
    }

    function safeDecimals(IERC20 token) public view returns (uint8) {
        (bool success, bytes memory data) = address(token).staticcall(abi.encodeWithSelector(0x313ce567));
        return success && data.length == 32 ? abi.decode(data, (uint8)) : 18;
    }

    function safeTransfer(
        IERC20 token,
        address to,
        uint256 amount
    ) internal {
        (bool success, bytes memory data) = address(token).call(abi.encodeWithSelector(0xa9059cbb, to, amount));
        require(success && (data.length == 0 || abi.decode(data, (bool))), "SafeERC20: Transfer failed");
    }

    function safeTransferFrom(
        IERC20 token,
        address from,
        uint256 amount
    ) internal {
        (bool success, bytes memory data) = address(token).call(
            abi.encodeWithSelector(0x23b872dd, from, address(this), amount)
        );
        require(success && (data.length == 0 || abi.decode(data, (bool))), "SafeERC20: TransferFrom failed");
    }
}

File 4 of 12 : IERC20.sol
// SPDX-License-Identifier: GPL-3.0

pragma solidity >=0.5.0;

interface IERC20Joe {
    event Approval(address indexed owner, address indexed spender, uint256 value);
    event Transfer(address indexed from, address indexed to, uint256 value);

    function name() external view returns (string memory);

    function symbol() external view returns (string memory);

    function decimals() external view returns (uint8);

    function totalSupply() external view returns (uint256);

    function balanceOf(address owner) external view returns (uint256);

    function allowance(address owner, address spender) external view returns (uint256);

    function approve(address spender, uint256 value) external returns (bool);

    function transfer(address to, uint256 value) external returns (bool);

    function transferFrom(
        address from,
        address to,
        uint256 value
    ) external returns (bool);
}

File 5 of 12 : IJoePair.sol
// SPDX-License-Identifier: GPL-3.0

pragma solidity >=0.5.0;

interface IJoePair {
    event Approval(address indexed owner, address indexed spender, uint256 value);
    event Transfer(address indexed from, address indexed to, uint256 value);

    function name() external pure returns (string memory);

    function symbol() external pure returns (string memory);

    function decimals() external pure returns (uint8);

    function totalSupply() external view returns (uint256);

    function balanceOf(address owner) external view returns (uint256);

    function allowance(address owner, address spender) external view returns (uint256);

    function approve(address spender, uint256 value) external returns (bool);

    function transfer(address to, uint256 value) external returns (bool);

    function transferFrom(
        address from,
        address to,
        uint256 value
    ) external returns (bool);

    function DOMAIN_SEPARATOR() external view returns (bytes32);

    function PERMIT_TYPEHASH() external pure returns (bytes32);

    function nonces(address owner) external view returns (uint256);

    function permit(
        address owner,
        address spender,
        uint256 value,
        uint256 deadline,
        uint8 v,
        bytes32 r,
        bytes32 s
    ) external;

    event Mint(address indexed sender, uint256 amount0, uint256 amount1);
    event Burn(address indexed sender, uint256 amount0, uint256 amount1, address indexed to);
    event Swap(
        address indexed sender,
        uint256 amount0In,
        uint256 amount1In,
        uint256 amount0Out,
        uint256 amount1Out,
        address indexed to
    );
    event Sync(uint112 reserve0, uint112 reserve1);

    function MINIMUM_LIQUIDITY() external pure returns (uint256);

    function factory() external view returns (address);

    function token0() external view returns (address);

    function token1() external view returns (address);

    function getReserves()
        external
        view
        returns (
            uint112 reserve0,
            uint112 reserve1,
            uint32 blockTimestampLast
        );

    function price0CumulativeLast() external view returns (uint256);

    function price1CumulativeLast() external view returns (uint256);

    function kLast() external view returns (uint256);

    function mint(address to) external returns (uint256 liquidity);

    function burn(address to) external returns (uint256 amount0, uint256 amount1);

    function swap(
        uint256 amount0Out,
        uint256 amount1Out,
        address to,
        bytes calldata data
    ) external;

    function skim(address to) external;

    function sync() external;

    function initialize(address, address) external;
}

File 6 of 12 : IJoeFactory.sol
// SPDX-License-Identifier: GPL-3.0

pragma solidity >=0.5.0;

interface IJoeFactory {
    event PairCreated(address indexed token0, address indexed token1, address pair, uint256);

    function feeTo() external view returns (address);

    function feeToSetter() external view returns (address);

    function migrator() external view returns (address);

    function getPair(address tokenA, address tokenB) external view returns (address pair);

    function allPairs(uint256) external view returns (address pair);

    function allPairsLength() external view returns (uint256);

    function createPair(address tokenA, address tokenB) external returns (address pair);

    function setFeeTo(address) external;

    function setFeeToSetter(address) external;

    function setMigrator(address) external;
}

File 7 of 12 : JoeLibrary.sol
// SPDX-License-Identifier: GPL-3.0

pragma solidity >=0.5.0;

import "../interfaces/IJoePair.sol";

import "./SafeMath.sol";

library JoeLibrary {
    using SafeMathJoe for uint256;

    // returns sorted token addresses, used to handle return values from pairs sorted in this order
    function sortTokens(address tokenA, address tokenB) internal pure returns (address token0, address token1) {
        require(tokenA != tokenB, "JoeLibrary: IDENTICAL_ADDRESSES");
        (token0, token1) = tokenA < tokenB ? (tokenA, tokenB) : (tokenB, tokenA);
        require(token0 != address(0), "JoeLibrary: ZERO_ADDRESS");
    }

    // calculates the CREATE2 address for a pair without making any external calls
    function pairFor(
        address factory,
        address tokenA,
        address tokenB
    ) internal pure returns (address pair) {
        (address token0, address token1) = sortTokens(tokenA, tokenB);
        pair = address(
            uint256(
                keccak256(
                    abi.encodePacked(
                        hex"ff",
                        factory,
                        keccak256(abi.encodePacked(token0, token1)),
                        hex"0bbca9af0511ad1a1da383135cf3a8d2ac620e549ef9f6ae3a4c33c2fed0af91" // init code fuji
                    )
                )
            )
        );
    }

    // fetches and sorts the reserves for a pair
    function getReserves(
        address factory,
        address tokenA,
        address tokenB
    ) internal view returns (uint256 reserveA, uint256 reserveB) {
        (address token0, ) = sortTokens(tokenA, tokenB);
        (uint256 reserve0, uint256 reserve1, ) = IJoePair(pairFor(factory, tokenA, tokenB)).getReserves();
        (reserveA, reserveB) = tokenA == token0 ? (reserve0, reserve1) : (reserve1, reserve0);
    }

    // given some amount of an asset and pair reserves, returns an equivalent amount of the other asset
    function quote(
        uint256 amountA,
        uint256 reserveA,
        uint256 reserveB
    ) internal pure returns (uint256 amountB) {
        require(amountA > 0, "JoeLibrary: INSUFFICIENT_AMOUNT");
        require(reserveA > 0 && reserveB > 0, "JoeLibrary: INSUFFICIENT_LIQUIDITY");
        amountB = amountA.mul(reserveB) / reserveA;
    }

    // given an input amount of an asset and pair reserves, returns the maximum output amount of the other asset
    function getAmountOut(
        uint256 amountIn,
        uint256 reserveIn,
        uint256 reserveOut
    ) internal pure returns (uint256 amountOut) {
        require(amountIn > 0, "JoeLibrary: INSUFFICIENT_INPUT_AMOUNT");
        require(reserveIn > 0 && reserveOut > 0, "JoeLibrary: INSUFFICIENT_LIQUIDITY");
        uint256 amountInWithFee = amountIn.mul(997);
        uint256 numerator = amountInWithFee.mul(reserveOut);
        uint256 denominator = reserveIn.mul(1000).add(amountInWithFee);
        amountOut = numerator / denominator;
    }

    // given an output amount of an asset and pair reserves, returns a required input amount of the other asset
    function getAmountIn(
        uint256 amountOut,
        uint256 reserveIn,
        uint256 reserveOut
    ) internal pure returns (uint256 amountIn) {
        require(amountOut > 0, "JoeLibrary: INSUFFICIENT_OUTPUT_AMOUNT");
        require(reserveIn > 0 && reserveOut > 0, "JoeLibrary: INSUFFICIENT_LIQUIDITY");
        uint256 numerator = reserveIn.mul(amountOut).mul(1000);
        uint256 denominator = reserveOut.sub(amountOut).mul(997);
        amountIn = (numerator / denominator).add(1);
    }

    // performs chained getAmountOut calculations on any number of pairs
    function getAmountsOut(
        address factory,
        uint256 amountIn,
        address[] memory path
    ) internal view returns (uint256[] memory amounts) {
        require(path.length >= 2, "JoeLibrary: INVALID_PATH");
        amounts = new uint256[](path.length);
        amounts[0] = amountIn;
        for (uint256 i; i < path.length - 1; i++) {
            (uint256 reserveIn, uint256 reserveOut) = getReserves(factory, path[i], path[i + 1]);
            amounts[i + 1] = getAmountOut(amounts[i], reserveIn, reserveOut);
        }
    }

    // performs chained getAmountIn calculations on any number of pairs
    function getAmountsIn(
        address factory,
        uint256 amountOut,
        address[] memory path
    ) internal view returns (uint256[] memory amounts) {
        require(path.length >= 2, "JoeLibrary: INVALID_PATH");
        amounts = new uint256[](path.length);
        amounts[amounts.length - 1] = amountOut;
        for (uint256 i = path.length - 1; i > 0; i--) {
            (uint256 reserveIn, uint256 reserveOut) = getReserves(factory, path[i - 1], path[i]);
            amounts[i - 1] = getAmountIn(amounts[i], reserveIn, reserveOut);
        }
    }
}

File 8 of 12 : Ownable.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.6.0 <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 () internal {
        address msgSender = _msgSender();
        _owner = msgSender;
        emit OwnershipTransferred(address(0), 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 {
        emit OwnershipTransferred(_owner, address(0));
        _owner = 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");
        emit OwnershipTransferred(_owner, newOwner);
        _owner = newOwner;
    }
}

File 9 of 12 : EnumerableSet.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.6.0 <0.8.0;

/**
 * @dev Library for managing
 * https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive
 * types.
 *
 * Sets have the following properties:
 *
 * - Elements are added, removed, and checked for existence in constant time
 * (O(1)).
 * - Elements are enumerated in O(n). No guarantees are made on the ordering.
 *
 * ```
 * contract Example {
 *     // Add the library methods
 *     using EnumerableSet for EnumerableSet.AddressSet;
 *
 *     // Declare a set state variable
 *     EnumerableSet.AddressSet private mySet;
 * }
 * ```
 *
 * As of v3.3.0, sets of type `bytes32` (`Bytes32Set`), `address` (`AddressSet`)
 * and `uint256` (`UintSet`) are supported.
 */
library EnumerableSet {
    // To implement this library for multiple types with as little code
    // repetition as possible, we write it in terms of a generic Set type with
    // bytes32 values.
    // The Set implementation uses private functions, and user-facing
    // implementations (such as AddressSet) are just wrappers around the
    // underlying Set.
    // This means that we can only create new EnumerableSets for types that fit
    // in bytes32.

    struct Set {
        // Storage of set values
        bytes32[] _values;

        // Position of the value in the `values` array, plus 1 because index 0
        // means a value is not in the set.
        mapping (bytes32 => uint256) _indexes;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function _add(Set storage set, bytes32 value) private returns (bool) {
        if (!_contains(set, value)) {
            set._values.push(value);
            // The value is stored at length-1, but we add 1 to all indexes
            // and use 0 as a sentinel value
            set._indexes[value] = set._values.length;
            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function _remove(Set storage set, bytes32 value) private returns (bool) {
        // We read and store the value's index to prevent multiple reads from the same storage slot
        uint256 valueIndex = set._indexes[value];

        if (valueIndex != 0) { // Equivalent to contains(set, value)
            // To delete an element from the _values array in O(1), we swap the element to delete with the last one in
            // the array, and then remove the last element (sometimes called as 'swap and pop').
            // This modifies the order of the array, as noted in {at}.

            uint256 toDeleteIndex = valueIndex - 1;
            uint256 lastIndex = set._values.length - 1;

            // When the value to delete is the last one, the swap operation is unnecessary. However, since this occurs
            // so rarely, we still do the swap anyway to avoid the gas cost of adding an 'if' statement.

            bytes32 lastvalue = set._values[lastIndex];

            // Move the last value to the index where the value to delete is
            set._values[toDeleteIndex] = lastvalue;
            // Update the index for the moved value
            set._indexes[lastvalue] = toDeleteIndex + 1; // All indexes are 1-based

            // Delete the slot where the moved value was stored
            set._values.pop();

            // Delete the index for the deleted slot
            delete set._indexes[value];

            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function _contains(Set storage set, bytes32 value) private view returns (bool) {
        return set._indexes[value] != 0;
    }

    /**
     * @dev Returns the number of values on the set. O(1).
     */
    function _length(Set storage set) private view returns (uint256) {
        return set._values.length;
    }

   /**
    * @dev Returns the value stored at position `index` in the set. O(1).
    *
    * Note that there are no guarantees on the ordering of values inside the
    * array, and it may change when more values are added or removed.
    *
    * Requirements:
    *
    * - `index` must be strictly less than {length}.
    */
    function _at(Set storage set, uint256 index) private view returns (bytes32) {
        require(set._values.length > index, "EnumerableSet: index out of bounds");
        return set._values[index];
    }

    // Bytes32Set

    struct Bytes32Set {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(Bytes32Set storage set, bytes32 value) internal returns (bool) {
        return _add(set._inner, value);
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(Bytes32Set storage set, bytes32 value) internal returns (bool) {
        return _remove(set._inner, value);
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(Bytes32Set storage set, bytes32 value) internal view returns (bool) {
        return _contains(set._inner, value);
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(Bytes32Set storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

   /**
    * @dev Returns the value stored at position `index` in the set. O(1).
    *
    * Note that there are no guarantees on the ordering of values inside the
    * array, and it may change when more values are added or removed.
    *
    * Requirements:
    *
    * - `index` must be strictly less than {length}.
    */
    function at(Bytes32Set storage set, uint256 index) internal view returns (bytes32) {
        return _at(set._inner, index);
    }

    // AddressSet

    struct AddressSet {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(AddressSet storage set, address value) internal returns (bool) {
        return _add(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(AddressSet storage set, address value) internal returns (bool) {
        return _remove(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(AddressSet storage set, address value) internal view returns (bool) {
        return _contains(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(AddressSet storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

   /**
    * @dev Returns the value stored at position `index` in the set. O(1).
    *
    * Note that there are no guarantees on the ordering of values inside the
    * array, and it may change when more values are added or removed.
    *
    * Requirements:
    *
    * - `index` must be strictly less than {length}.
    */
    function at(AddressSet storage set, uint256 index) internal view returns (address) {
        return address(uint160(uint256(_at(set._inner, index))));
    }


    // UintSet

    struct UintSet {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(UintSet storage set, uint256 value) internal returns (bool) {
        return _add(set._inner, bytes32(value));
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(UintSet storage set, uint256 value) internal returns (bool) {
        return _remove(set._inner, bytes32(value));
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(UintSet storage set, uint256 value) internal view returns (bool) {
        return _contains(set._inner, bytes32(value));
    }

    /**
     * @dev Returns the number of values on the set. O(1).
     */
    function length(UintSet storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

   /**
    * @dev Returns the value stored at position `index` in the set. O(1).
    *
    * Note that there are no guarantees on the ordering of values inside the
    * array, and it may change when more values are added or removed.
    *
    * Requirements:
    *
    * - `index` must be strictly less than {length}.
    */
    function at(UintSet storage set, uint256 index) internal view returns (uint256) {
        return uint256(_at(set._inner, index));
    }
}

File 10 of 12 : IERC20.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.6.12;

interface IERC20 {
    function totalSupply() external view returns (uint256);

    function balanceOf(address account) external view returns (uint256);

    function allowance(address owner, address spender) external view returns (uint256);

    function approve(address spender, uint256 amount) external returns (bool);

    event Transfer(address indexed from, address indexed to, uint256 value);
    event Approval(address indexed owner, address indexed spender, uint256 value);

    // EIP 2612
    function permit(
        address owner,
        address spender,
        uint256 value,
        uint256 deadline,
        uint8 v,
        bytes32 r,
        bytes32 s
    ) external;
}

File 11 of 12 : SafeMath.sol
// SPDX-License-Identifier: GPL-3.0

pragma solidity =0.6.12;

// a library for performing overflow-safe math, courtesy of DappHub (https://github.com/dapphub/ds-math)

library SafeMathJoe {
    function add(uint256 x, uint256 y) internal pure returns (uint256 z) {
        require((z = x + y) >= x, "ds-math-add-overflow");
    }

    function sub(uint256 x, uint256 y) internal pure returns (uint256 z) {
        require((z = x - y) <= x, "ds-math-sub-underflow");
    }

    function mul(uint256 x, uint256 y) internal pure returns (uint256 z) {
        require(y == 0 || (z = x * y) / y == x, "ds-math-mul-overflow");
    }
}

File 12 of 12 : Context.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.6.0 <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 GSN 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 payable) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes memory) {
        this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
        return msg.data;
    }
}

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

Contract ABI

[{"inputs":[{"internalType":"address","name":"_factory","type":"address"},{"internalType":"address","name":"_bar","type":"address"},{"internalType":"address","name":"_tokenTo","type":"address"},{"internalType":"address","name":"_wavax","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_addr","type":"address"}],"name":"AddAuthorizedAddress","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"token","type":"address"},{"indexed":true,"internalType":"address","name":"oldBridge","type":"address"},{"indexed":true,"internalType":"address","name":"bridge","type":"address"}],"name":"LogBridgeSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"server","type":"address"},{"indexed":true,"internalType":"address","name":"token0","type":"address"},{"indexed":true,"internalType":"address","name":"token1","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount0","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount1","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amountTOKEN","type":"uint256"}],"name":"LogConvert","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":true,"internalType":"address","name":"_addr","type":"address"}],"name":"RemoveAuthorizedAddress","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_addr","type":"address"}],"name":"SetDevAddr","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"SetDevCut","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_tokenTo","type":"address"}],"name":"SetTokenTo","type":"event"},{"inputs":[{"internalType":"address","name":"_auth","type":"address"}],"name":"addAuth","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"bar","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"token","type":"address"}],"name":"bridgeFor","outputs":[{"internalType":"address","name":"bridge","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"token0","type":"address"},{"internalType":"address","name":"token1","type":"address"},{"internalType":"uint256","name":"slippage","type":"uint256"}],"name":"convert","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"token0","type":"address[]"},{"internalType":"address[]","name":"token1","type":"address[]"},{"internalType":"uint256","name":"slippage","type":"uint256"}],"name":"convertMultiple","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"devAddr","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"devCut","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"factory","outputs":[{"internalType":"contract IJoeFactory","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"getAuth","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"lenAuth","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_auth","type":"address"}],"name":"removeAuth","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"token","type":"address"},{"internalType":"address","name":"bridge","type":"address"}],"name":"setBridge","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_addr","type":"address"}],"name":"setDevAddr","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"setDevCut","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_tokenTo","type":"address"}],"name":"setTokenToAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"tokenTo","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60e060405260006002553480156200001657600080fd5b506040516200295338038062002953833981810160405260808110156200003c57600080fd5b508051602082015160408301516060909301519192909160006200005f6200025d565b600080546001600160a01b0319166001600160a01b0383169081178255604051929350917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a3506001600160a01b038416620000f05760405162461bcd60e51b8152600401808060200182810382526027815260200180620028e46027913960400191505060405180910390fd5b6001600160a01b038316620001375760405162461bcd60e51b81526004018080602001828103825260238152602001806200290b6023913960400191505060405180910390fd5b6001600160a01b0382166200017e5760405162461bcd60e51b81526004018080602001828103825260258152602001806200292e6025913960400191505060405180910390fd5b6001600160a01b038116620001c55760405162461bcd60e51b8152600401808060200182810382526025815260200180620028bf6025913960400191505060405180910390fd5b6001600160601b0319606085811b821660805284811b821660a052600180546001600160a01b0386166001600160a01b031990911617905582901b1660c0526200020e6200025d565b600380546001600160a01b0319166001600160a01b0392909216919091179055620002526200023c6200025d565b60046200026160201b62000f291790919060201c565b5050505050620002e8565b3390565b600062000278836001600160a01b03841662000281565b90505b92915050565b60006200028f8383620002d0565b620002c7575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556200027b565b5060006200027b565b60009081526001919091016020526040902054151590565b60805160601c60a05160601c60c05160601c6125566200036960003980610b7e5280610ca952806117155280611752528061187a52806118b752806118e0528061190f528061194c5280611975525080610f0752806116e652806117db52806118445280611c39525080610cde52806110095280611c5f52506125566000f3fe608060405234801561001057600080fd5b50600436106101215760003560e01c80638da5cb5b116100ad578063c45a015511610071578063c45a01551461037f578063da09c72c14610387578063dbcc106d1461038f578063f2fde38b146103ac578063febb0f7e146103d257610121565b80638da5cb5b146103135780639c2868371461031b5780639d22ae8c14610323578063a761a93914610351578063c17b73261461037757610121565b80635422224e116100f45780635422224e146102605780636ebb64a214610286578063715018a6146102ac5780637ccaacbb146102b45780637f3fd918146102ed57610121565b8063159e6f07146101265780631d380d3f14610140578063248391ff146101685780633feb270e1461019e575b600080fd5b61012e6103da565b60408051918252519081900360200190f35b6101666004803603602081101561015657600080fd5b50356001600160a01b03166103eb565b005b6101666004803603606081101561017e57600080fd5b506001600160a01b038135811691602081013590911690604001356104e6565b610166600480360360608110156101b457600080fd5b8101906020810181356401000000008111156101cf57600080fd5b8201836020820111156101e157600080fd5b8035906020019184602083028401116401000000008311171561020357600080fd5b91939092909160208101903564010000000081111561022157600080fd5b82018360208201111561023357600080fd5b8035906020019184602083028401116401000000008311171561025557600080fd5b9193509150356105f1565b6101666004803603602081101561027657600080fd5b50356001600160a01b0316610780565b6101666004803603602081101561029c57600080fd5b50356001600160a01b031661085f565b61016661095a565b6102d1600480360360208110156102ca57600080fd5b5035610a06565b604080516001600160a01b039092168252519081900360200190f35b6101666004803603602081101561030357600080fd5b50356001600160a01b0316610a1b565b6102d1610afa565b61012e610b09565b6101666004803603604081101561033957600080fd5b506001600160a01b0381358116916020013516610b0f565b6102d16004803603602081101561036757600080fd5b50356001600160a01b0316610c86565b6102d1610ccd565b6102d1610cdc565b6102d1610d00565b610166600480360360208110156103a557600080fd5b5035610d0f565b610166600480360360208110156103c257600080fd5b50356001600160a01b0316610e03565b6102d1610f05565b60006103e66004610f47565b905090565b6103f3610f52565b6001600160a01b0316610404610afa565b6001600160a01b03161461044d576040805162461bcd60e51b815260206004820181905260248201526000805160206124b2833981519152604482015290519081900360640190fd5b6001600160a01b0381166104925760405162461bcd60e51b81526004018080602001828103825260318152602001806124586031913960400191505060405180910390fd5b600180546001600160a01b0383166001600160a01b0319909116811790915560408051918252517fbf32c8b1124ae0b6584a5354b035cdfbcfbbba82075e3c7bffc9bf655dc5376e9181900360200190a150565b326104ef610f52565b6001600160a01b031614610545576040805162461bcd60e51b81526020600482015260186024820152774d6f6e65794d616b65723a206d7573742075736520454f4160401b604482015290519081900360640190fd5b610558610550610f52565b600490610f56565b6105a1576040805162461bcd60e51b815260206004820152601560248201527426b7b732bca6b0b5b2b91d102327a92124a22222a760591b604482015290519081900360640190fd5b61138881106105e15760405162461bcd60e51b815260040180806020018281038252602f815260200180612397602f913960400191505060405180910390fd5b6105ec838383610f6b565b505050565b326105fa610f52565b6001600160a01b031614610650576040805162461bcd60e51b81526020600482015260186024820152774d6f6e65794d616b65723a206d7573742075736520454f4160401b604482015290519081900360640190fd5b61065b610550610f52565b6106a4576040805162461bcd60e51b815260206004820152601560248201527426b7b732bca6b0b5b2b91d102327a92124a22222a760591b604482015290519081900360640190fd5b61138881106106e45760405162461bcd60e51b815260040180806020018281038252602f815260200180612397602f913960400191505060405180910390fd5b8382146107225760405162461bcd60e51b815260040180806020018281038252602581526020018061240e6025913960400191505060405180910390fd5b8360005b818110156107775761076f87878381811061073d57fe5b905060200201356001600160a01b031686868481811061075957fe5b905060200201356001600160a01b031685610f6b565b600101610726565b50505050505050565b610788610f52565b6001600160a01b0316610799610afa565b6001600160a01b0316146107e2576040805162461bcd60e51b815260206004820181905260248201526000805160206124b2833981519152604482015290519081900360640190fd5b6107ed600482610f29565b6108285760405162461bcd60e51b81526004018080602001828103825260298152602001806124896029913960400191505060405180910390fd5b6040516001600160a01b038216907f030e24b250019d43c83e1350821892b74b895598b35969ae338242047c815b4990600090a250565b610867610f52565b6001600160a01b0316610878610afa565b6001600160a01b0316146108c1576040805162461bcd60e51b815260206004820181905260248201526000805160206124b2833981519152604482015290519081900360640190fd5b6001600160a01b0381166109065760405162461bcd60e51b815260040180806020018281038252602a8152602001806124f7602a913960400191505060405180910390fd5b600380546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f45c73fc162405abe4471c4228f0797176ac32cb9f7be4a25a67cbd1dda6d007e9181900360200190a150565b610962610f52565b6001600160a01b0316610973610afa565b6001600160a01b0316146109bc576040805162461bcd60e51b815260206004820181905260248201526000805160206124b2833981519152604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b6000610a13600483611454565b90505b919050565b610a23610f52565b6001600160a01b0316610a34610afa565b6001600160a01b031614610a7d576040805162461bcd60e51b815260206004820181905260248201526000805160206124b2833981519152604482015290519081900360640190fd5b610a88600482611460565b610ac35760405162461bcd60e51b81526004018080602001828103825260258152602001806124336025913960400191505060405180910390fd5b6040516001600160a01b038216907ff39efc52b4beccf22e624f7c591cc2dbfdb4359a0fe0801b1319d162833c0ec590600090a250565b6000546001600160a01b031690565b60025481565b610b1a610550610f52565b610b63576040805162461bcd60e51b815260206004820152601560248201527426b7b732bca6b0b5b2b91d102327a92124a22222a760591b604482015290519081900360640190fd5b6001546001600160a01b03838116911614801590610bb357507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316826001600160a01b031614155b8015610bd15750806001600160a01b0316826001600160a01b031614155b610c22576040805162461bcd60e51b815260206004820152601a60248201527f4d6f6e65794d616b65723a20496e76616c696420627269646765000000000000604482015290519081900360640190fd5b6001600160a01b0380831660008181526006602052604080822080548686166001600160a01b0319821681179092559151919094169392849290917f15e77ca45c8933ccd9fb9c909fd297b4ff5f8b931ba6e5d9df3edbc88f172c149190a4505050565b6001600160a01b038082166000908152600660205260409020541680610a1657507f0000000000000000000000000000000000000000000000000000000000000000919050565b6001546001600160a01b031681565b7f000000000000000000000000000000000000000000000000000000000000000081565b6003546001600160a01b031681565b610d17610f52565b6001600160a01b0316610d28610afa565b6001600160a01b031614610d71576040805162461bcd60e51b815260206004820181905260248201526000805160206124b2833981519152604482015290519081900360640190fd5b611388811115610dc8576040805162461bcd60e51b815260206004820152601760248201527f7365744465764375743a2063757420746f6f2068696768000000000000000000604482015290519081900360640190fd5b60028190556040805182815290517f914990c75916d406c148e7fca9308486d7806a77c0ef66119c9329add5885d2e9181900360200190a150565b610e0b610f52565b6001600160a01b0316610e1c610afa565b6001600160a01b031614610e65576040805162461bcd60e51b815260206004820181905260248201526000805160206124b2833981519152604482015290519081900360640190fd5b6001600160a01b038116610eaa5760405162461bcd60e51b81526004018080602001828103825260268152602001806123c66026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b7f000000000000000000000000000000000000000000000000000000000000000081565b6000610f3e836001600160a01b038416611475565b90505b92915050565b6000610a13826114bf565b3390565b6000610f3e836001600160a01b0384166114c3565b600080836001600160a01b0316856001600160a01b0316141561100557604080516370a0823160e01b815230600482015290516001600160a01b038716916370a08231916024808301926020929190829003018186803b158015610fce57600080fd5b505afa158015610fe2573d6000803e3d6000fd5b505050506040513d6020811015610ff857600080fd5b50519150600090506113db565b60007f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663e6a4390587876040518363ffffffff1660e01b815260040180836001600160a01b03168152602001826001600160a01b031681526020019250505060206040518083038186803b15801561108557600080fd5b505afa158015611099573d6000803e3d6000fd5b505050506040513d60208110156110af57600080fd5b505190506001600160a01b03811661110e576040805162461bcd60e51b815260206004820152601860248201527f4d6f6e65794d616b65723a20496e76616c696420706169720000000000000000604482015290519081900360640190fd5b61119c81826001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b15801561115f57600080fd5b505afa158015611173573d6000803e3d6000fd5b505050506040513d602081101561118957600080fd5b50516001600160a01b03841691906114db565b6000866001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b1580156111eb57600080fd5b505afa1580156111ff573d6000803e3d6000fd5b505050506040513d602081101561121557600080fd5b5051604080516370a0823160e01b815230600482015290519192506000916001600160a01b038916916370a08231916024808301926020929190829003018186803b15801561126357600080fd5b505afa158015611277573d6000803e3d6000fd5b505050506040513d602081101561128d57600080fd5b50516040805163226bf2d160e21b815230600482015281519293506001600160a01b038616926389afcb44926024808401939192918290030181600087803b1580156112d857600080fd5b505af11580156112ec573d6000803e3d6000fd5b505050506040513d604081101561130257600080fd5b5050604080516370a0823160e01b815230600482015290516113829184916001600160a01b038c16916370a08231916024808301926020929190829003018186803b15801561135057600080fd5b505afa158015611364573d6000803e3d6000fd5b505050506040513d602081101561137a57600080fd5b505190611645565b94506113d581886001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b15801561135057600080fd5b93505050505b836001600160a01b0316856001600160a01b03166113f7610f52565b6001600160a01b03167fd06b1d7ed79b664d17472c6f6997b929f1abe463ccccb4e5b6a0038f2f730c1585856114308b8b8a8a8d611693565b60408051938452602084019290925282820152519081900360600190a45050505050565b6000610f3e8383611a51565b6000610f3e836001600160a01b038416611ab5565b600061148183836114c3565b6114b757508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610f41565b506000610f41565b5490565b60009081526001919091016020526040902054151590565b604080516001600160a01b038481166024830152604480830185905283518084039091018152606490920183526020820180516001600160e01b031663a9059cbb60e01b178152925182516000946060949389169392918291908083835b602083106115585780518252601f199092019160209182019101611539565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d80600081146115ba576040519150601f19603f3d011682016040523d82523d6000602084013e6115bf565b606091505b50915091508180156115ed5750805115806115ed57508080602001905160208110156115ea57600080fd5b50515b61163e576040805162461bcd60e51b815260206004820152601a60248201527f5361666545524332303a205472616e73666572206661696c6564000000000000604482015290519081900360640190fd5b5050505050565b80820382811115610f41576040805162461bcd60e51b8152602060048201526013602482015272536166654d6174683a20556e646572666c6f7760681b604482015290519081900360640190fd5b6000846001600160a01b0316866001600160a01b031614156117b35760006116bb8585611b7b565b6001549091506001600160a01b03888116911614156117135760015461170b906001600160a01b03167f0000000000000000000000000000000000000000000000000000000000000000836114db565b8091506117ad565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316876001600160a01b0316141561177f576117787f00000000000000000000000000000000000000000000000000000000000000008285611bcc565b91506117ad565b600061178a88610c86565b90506117998882843088611c5a565b91506117a9818284600088611693565b9250505b50611a48565b6001546001600160a01b038781169116141561181c57600154611800906001600160a01b03167f0000000000000000000000000000000000000000000000000000000000000000866114db565b6118158461180f878686611bcc565b90611b7b565b9050611a48565b6001546001600160a01b038681169116141561187857600154611869906001600160a01b03167f0000000000000000000000000000000000000000000000000000000000000000856114db565b6118158361180f888786611bcc565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316866001600160a01b0316141561190d576118157f00000000000000000000000000000000000000000000000000000000000000006119078661180f897f000000000000000000000000000000000000000000000000000000000000000089308a611c5a565b84611bcc565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316856001600160a01b0316141561199c576118157f00000000000000000000000000000000000000000000000000000000000000006119078561180f8a7f00000000000000000000000000000000000000000000000000000000000000008a308a611c5a565b60006119a787610c86565b905060006119b487610c86565b9050866001600160a01b0316826001600160a01b031614156119f0576119e982886119e28b868b308b611c5a565b8888611693565b9250611a45565b876001600160a01b0316816001600160a01b03161415611a23576119e9888288611a1d8b868b308c611c5a565b88611693565b611a428282611a358b868b308b611c5a565b611a1d8b868b308c611c5a565b92505b50505b95945050505050565b81546000908210611a935760405162461bcd60e51b81526004018080602001828103825260228152602001806123756022913960400191505060405180910390fd5b826000018281548110611aa257fe5b9060005260206000200154905092915050565b60008181526001830160205260408120548015611b715783546000198083019190810190600090879083908110611ae857fe5b9060005260206000200154905080876000018481548110611b0557fe5b600091825260208083209091019290925582815260018981019092526040902090840190558654879080611b3557fe5b60019003818190600052602060002001600090559055866001016000878152602001908152602001600020600090556001945050505050610f41565b6000915050610f41565b81810181811015610f41576040805162461bcd60e51b8152602060048201526016602482015275536166654d6174683a20416464204f766572666c6f7760501b604482015290519081900360640190fd5b600254600090839015611c2457611bfa612710611bf46002548461212690919063ffffffff16565b9061218b565b600354909150611c17906001600160a01b038781169116836114db565b611c218482611645565b90505b600154611a489086906001600160a01b0316837f0000000000000000000000000000000000000000000000000000000000000000875b6000807f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663e6a4390588886040518363ffffffff1660e01b815260040180836001600160a01b03168152602001826001600160a01b031681526020019250505060206040518083038186803b158015611cdb57600080fd5b505afa158015611cef573d6000803e3d6000fd5b505050506040513d6020811015611d0557600080fd5b505190506001600160a01b038116611d64576040805162461bcd60e51b815260206004820152601a60248201527f4d6f6e65794d616b65723a2043616e6e6f7420636f6e76657274000000000000604482015290519081900360640190fd5b600080826001600160a01b0316630902f1ac6040518163ffffffff1660e01b815260040160606040518083038186803b158015611da057600080fd5b505afa158015611db4573d6000803e3d6000fd5b505050506040513d6060811015611dca57600080fd5b50805160209182015160408051630dfe168160e01b815290516dffffffffffffffffffffffffffff938416965092909116935060009283926001600160a01b03881692630dfe1681926004808301939192829003018186803b158015611e2f57600080fd5b505afa158015611e43573d6000803e3d6000fd5b505050506040513d6020811015611e5957600080fd5b50516001600160a01b038c8116911614611e74578284611e77565b83835b9092509050611e906001600160a01b038c16868b6114db565b6000611ee3838d6001600160a01b03166370a08231896040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b15801561135057600080fd5b9050611ef08184846121ea565b96506000611f006127108a611645565b9050611f1e6305f5e100611bf483611f188682612126565b90612126565b611f298985876121ea565b1015611f7c576040805162461bcd60e51b815260206004820152601b60248201527f4d6f6e65794d616b65723a20536c697070616765206361756768740000000000604482015290519081900360640190fd5b50600080876001600160a01b0316630dfe16816040518163ffffffff1660e01b815260040160206040518083038186803b158015611fb957600080fd5b505afa158015611fcd573d6000803e3d6000fd5b505050506040513d6020811015611fe357600080fd5b50516001600160a01b038f8116911614611fff57886000612003565b6000895b90925090506001600160a01b03881663022c0d9f83838e60006040519080825280601f01601f191660200182016040528015612046576020820181803683370190505b506040518563ffffffff1660e01b815260040180858152602001848152602001836001600160a01b0316815260200180602001828103825283818151815260200191508051906020019080838360005b838110156120ae578181015183820152602001612096565b50505050905090810190601f1680156120db5780820380516001836020036101000a031916815260200191505b5095505050505050600060405180830381600087803b1580156120fd57600080fd5b505af1158015612111573d6000803e3d6000fd5b50505050505050505050505095945050505050565b60008115806121415750508082028282828161213e57fe5b04145b610f41576040805162461bcd60e51b8152602060048201526016602482015275536166654d6174683a204d756c204f766572666c6f7760501b604482015290519081900360640190fd5b60008082116121d9576040805162461bcd60e51b8152602060048201526015602482015274536166654d6174683a20446976206279205a65726f60581b604482015290519081900360640190fd5b8183816121e257fe5b049392505050565b600080841161222a5760405162461bcd60e51b81526004018080602001828103825260258152602001806124d26025913960400191505060405180910390fd5b60008311801561223a5750600082115b6122755760405162461bcd60e51b81526004018080602001828103825260228152602001806123ec6022913960400191505060405180910390fd5b6000612283856103e56122c2565b9050600061229182856122c2565b905060006122ab836122a5886103e86122c2565b90612325565b90508082816122b657fe5b04979650505050505050565b60008115806122dd575050808202828282816122da57fe5b04145b610f41576040805162461bcd60e51b815260206004820152601460248201527364732d6d6174682d6d756c2d6f766572666c6f7760601b604482015290519081900360640190fd5b80820182811015610f41576040805162461bcd60e51b815260206004820152601460248201527364732d6d6174682d6164642d6f766572666c6f7760601b604482015290519081900360640190fdfe456e756d657261626c655365743a20696e646578206f7574206f6620626f756e64734d6f6e65794d616b65723a20736c697070616765206e6565647320746f206265206c6f776572207468616e203530254f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573734a6f654c6962726172793a20494e53554646494349454e545f4c49515549444954594d6f6e65794d616b65723a20617272617973206c656e67746820646f6e2774206d617463684d6f6e65794d616b65723a2041646472657373206973206e6f7420617574686f72697a6564736574546f6b656e546f416464726573732c20616464726573732063616e6e6f74206265207a65726f20616464726573734d6f6e65794d616b65723a204164647265737320697320616c726561647920617574686f72697a65644f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65724a6f654c6962726172793a20494e53554646494349454e545f494e5055545f414d4f554e54736574446576416464722c20616464726573732063616e6e6f74206265207a65726f2061646472657373a2646970667358221220333001c4cc8146f43839dd42c1bf0e4ee6a8ef49c7fa9074cb7147459661b8d164736f6c634300060c00334d6f6e65794d616b65723a2077617661782063616e277420626520616464726573732830294d6f6e65794d616b65723a20666163746f72792063616e277420626520616464726573732830294d6f6e65794d616b65723a206261722063616e277420626520616464726573732830294d6f6e65794d616b65723a20746f6b656e2063616e277420626520616464726573732830290000000000000000000000009ad6c38be94206ca50bb0d90783181662f0cfa100000000000000000000000001a731b2299e22fbac282e7094eda41046343cb51000000000000000000000000b97ef9ef8734c71904d8002f8b6bc66dd9c48a6e000000000000000000000000b31f66aa3c1e785363f0875a1b74e27b85fd66c7

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

0000000000000000000000009ad6c38be94206ca50bb0d90783181662f0cfa100000000000000000000000001a731b2299e22fbac282e7094eda41046343cb51000000000000000000000000b97ef9ef8734c71904d8002f8b6bc66dd9c48a6e000000000000000000000000b31f66aa3c1e785363f0875a1b74e27b85fd66c7

-----Decoded View---------------
Arg [0] : _factory (address): 0x9ad6c38be94206ca50bb0d90783181662f0cfa10
Arg [1] : _bar (address): 0x1a731b2299e22fbac282e7094eda41046343cb51
Arg [2] : _tokenTo (address): 0xb97ef9ef8734c71904d8002f8b6bc66dd9c48a6e
Arg [3] : _wavax (address): 0xb31f66aa3c1e785363f0875a1b74e27b85fd66c7

-----Encoded View---------------
4 Constructor Arguments found :
Arg [0] : 0000000000000000000000009ad6c38be94206ca50bb0d90783181662f0cfa10
Arg [1] : 0000000000000000000000001a731b2299e22fbac282e7094eda41046343cb51
Arg [2] : 000000000000000000000000b97ef9ef8734c71904d8002f8b6bc66dd9c48a6e
Arg [3] : 000000000000000000000000b31f66aa3c1e785363f0875a1b74e27b85fd66c7


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.