Contract 0x10cd224f252c18f2e9ff024dca1fb6e8550a9846

Contract Overview

Balance:
0 BTT
Txn Hash Method
Block
From
To
Value [Txn Fee]
0xa777c5d0da4c302f53bf2ef66bce73b552b0239f655a0f515ec2ebee49dd2766_become77763402022-05-31 9:28:01667 days 8 hrs ago0xa59340a7670c014ac038105ec04495d796169c00 IN  0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT7.7793
0xf1bee1e8ea382b5805f3135b8dd4c8e0535dd772162199eb72d9e730fa92366b0x6080604077762362022-05-31 9:23:43667 days 9 hrs ago0xa59340a7670c014ac038105ec04495d796169c00 IN  Create: Comptroller0 BTT1,534.6626
[ Download CSV Export 
Latest 25 internal transaction
Parent Txn Hash Block From To Value
0x5e5a6b3cc41f1b72ed95525c49110f83d12c0897514bbaf828c144b241ce42de99850092022-07-28 15:24:11609 days 3 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0x7165b5858267b689898568728a3bfef7daa5ce874b336d16a80721c650a5c4a799849412022-07-28 15:21:51609 days 3 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0x903b98d04fc168dac6d9b64b49f75be38a1a79888723f8de51fe4479819e01eb99849232022-07-28 15:21:15609 days 3 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0xc964a756dc94c8a4e9da8ce1729f3c868839e4469ffdc6a760b0cc85022c7ebf99848922022-07-28 15:20:09609 days 3 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0x2478d540bb6d825f7d35e16072a75e255e8eb089b406d1d7eb717282a08eb24599845442022-07-28 15:06:05609 days 3 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0xcfce440c43e3880575fab2bff7a1749ab28d86b13ce16d0416509ac7b42a43b599844182022-07-28 15:01:45609 days 3 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0x46e91197cf0918d52715b5b6188a78c7c7830ebca2ef4c08f7892ec2174fb1ee82711382022-06-13 12:50:13654 days 5 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0xfa37d09e39711331f42ac10d671c6ca474c14b028caed8a70d596a205e6b76a282630452022-06-13 7:40:33654 days 10 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0x2276d109b7e150cb0b899b1674f7a94cfbe1496fe0d671f9fe0bcab91d4113a782627502022-06-13 7:30:11654 days 10 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0x87052f1985cb14caaaa328ce8951f17d6fa1b655a28cc4a873d862c29c5a841682626142022-06-13 7:25:31654 days 11 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0xcb0bdd3f933694a5b3ddfbf48fc21c8a258b40d6c13c285ff8f0c26d0ecaeee882626062022-06-13 7:25:15654 days 11 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0x984c57cffcd966c2a981c99f654a73bf61f30d64aa5b992615eae3ec74d5a19582625432022-06-13 7:23:05654 days 11 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0x984c57cffcd966c2a981c99f654a73bf61f30d64aa5b992615eae3ec74d5a19582625432022-06-13 7:23:05654 days 11 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0xd128d713b1ef2554e02c6bd6a91de7a9ef319e1f601bda3a0dd8043ea82b69e882625282022-06-13 7:22:35654 days 11 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0xd128d713b1ef2554e02c6bd6a91de7a9ef319e1f601bda3a0dd8043ea82b69e882625282022-06-13 7:22:35654 days 11 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0x4514db05a3a0d87fabfaa86ae660c8e89c85c1d92fcf4550a41606ba6b934f1c82625172022-06-13 7:21:49654 days 11 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0x4514db05a3a0d87fabfaa86ae660c8e89c85c1d92fcf4550a41606ba6b934f1c82625172022-06-13 7:21:49654 days 11 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0xaf72904c2be54c35740b6d026dc589784e5921eca6f461ccd0134aa1ea98466282625122022-06-13 7:21:29654 days 11 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0x0115030c8d8bd506e82e609dbc4860f137ddc4da7809ee2c76b080128159798282624322022-06-13 7:17:07654 days 11 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0x983841ef98af5e0f40335875de3d01c804bca406805385b9440c7187b8e6383d81597522022-06-10 14:06:14657 days 4 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0x01f2fdfe858a6182df7e2a6c73ebf5c8658b33198231a48670869f2f05b7158181597162022-06-10 14:04:58657 days 4 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0x1aca232d782396fcd3f0bfd49b000376c51f82aef106a3455ebb422102476ea881597082022-06-10 14:04:42657 days 4 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0x73f6a1c6bdc32c4a4866f2918f8b5a2864f81168c1ba0c893f4adaf24418f14d81597002022-06-10 14:04:26657 days 4 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0x026805d2cfe2a905944a3b8c822083e6bd36a6b6b526ee0c9e6cf19c1d3405e681596882022-06-10 14:04:02657 days 4 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
0xa4958e0edca453d5a11a2d9f9a79bc4d6af4d74ac97a96d51d77bdde010ada9581596752022-06-10 14:03:32657 days 4 hrs ago 0xda90867de97856d73480970ba692168828263710 0x10cd224f252c18f2e9ff024dca1fb6e8550a98460 BTT
[ Download CSV Export 
Index Block
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
Comptroller

Compiler Version
v0.5.17+commit.d19bba13

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion, None license

Contract Source Code (Solidity)

/**
 *Submitted for verification at testnet.bttcscan.com on 2022-05-31
*/

// File: contracts/ComptrollerInterface.sol

pragma solidity ^0.5.16;

contract ComptrollerInterface {
    /// @notice Indicator that this is a Comptroller contract (for inspection)
    bool public constant isComptroller = true;

    /*** Assets You Are In ***/

    function enterMarkets(address[] calldata aTokens) external returns (uint[] memory);
    function exitMarket(address aToken) external returns (uint);

    /*** Policy Hooks ***/

    function mintAllowed(address aToken, address minter, uint mintAmount) external returns (uint);
    function mintVerify(address aToken, address minter, uint mintAmount, uint mintTokens) external;

    function redeemAllowed(address aToken, address redeemer, uint redeemTokens) external returns (uint);
    function redeemVerify(address aToken, address redeemer, uint redeemAmount, uint redeemTokens) external;

    function borrowAllowed(address aToken, address borrower, uint borrowAmount) external returns (uint);
    function borrowVerify(address aToken, address borrower, uint borrowAmount) external;

    function repayBorrowAllowed(
        address aToken,
        address payer,
        address borrower,
        uint repayAmount) external returns (uint);
    function repayBorrowVerify(
        address aToken,
        address payer,
        address borrower,
        uint repayAmount,
        uint borrowerIndex) external;

    function liquidateBorrowAllowed(
        address aTokenBorrowed,
        address aTokenCollateral,
        address liquidator,
        address borrower,
        uint repayAmount) external returns (uint);
    function liquidateBorrowVerify(
        address aTokenBorrowed,
        address aTokenCollateral,
        address liquidator,
        address borrower,
        uint repayAmount,
        uint seizeTokens) external;

    function seizeAllowed(
        address aTokenCollateral,
        address aTokenBorrowed,
        address liquidator,
        address borrower,
        uint seizeTokens) external returns (uint);
    function seizeVerify(
        address aTokenCollateral,
        address aTokenBorrowed,
        address liquidator,
        address borrower,
        uint seizeTokens) external;

    function transferAllowed(address aToken, address src, address dst, uint transferTokens) external returns (uint);
    function transferVerify(address aToken, address src, address dst, uint transferTokens) external;

    /*** Liquidity/Liquidation Calculations ***/

    function liquidateCalculateSeizeTokens(
        address aTokenBorrowed,
        address aTokenCollateral,
        uint repayAmount) external view returns (uint, uint);
}

// File: contracts/InterestRateModel.sol

pragma solidity ^0.5.16;

/**
  * @title Aquarius's InterestRateModel Interface
  * @author Aquarius
  */
contract InterestRateModel {
    /// @notice Indicator that this is an InterestRateModel contract (for inspection)
    bool public constant isInterestRateModel = true;

    /**
      * @notice Calculates the current borrow interest rate per block
      * @param cash The total amount of cash the market has
      * @param borrows The total amount of borrows the market has outstanding
      * @param reserves The total amount of reserves the market has
      * @return The borrow rate per block (as a percentage, and scaled by 1e18)
      */
    function getBorrowRate(uint cash, uint borrows, uint reserves) external view returns (uint);

    /**
      * @notice Calculates the current supply interest rate per block
      * @param cash The total amount of cash the market has
      * @param borrows The total amount of borrows the market has outstanding
      * @param reserves The total amount of reserves the market has
      * @param reserveFactorMantissa The current reserve factor the market has
      * @return The supply rate per block (as a percentage, and scaled by 1e18)
      */
    function getSupplyRate(uint cash, uint borrows, uint reserves, uint reserveFactorMantissa) external view returns (uint);

}

// File: contracts/EIP20NonStandardInterface.sol

pragma solidity ^0.5.16;

/**
 * @title EIP20NonStandardInterface
 * @dev Version of ERC20 with no return values for `transfer` and `transferFrom`
 *  See https://medium.com/coinmonks/missing-return-value-bug-at-least-130-tokens-affected-d67bf08521ca
 */
interface EIP20NonStandardInterface {

    /**
     * @notice Get the total number of tokens in circulation
     * @return The supply of tokens
     */
    function totalSupply() external view returns (uint256);

    /**
     * @notice Gets the balance of the specified address
     * @param owner The address from which the balance will be retrieved
     * @return The balance
     */
    function balanceOf(address owner) external view returns (uint256 balance);

    ///
    /// !!!!!!!!!!!!!!
    /// !!! NOTICE !!! `transfer` does not return a value, in violation of the ERC-20 specification
    /// !!!!!!!!!!!!!!
    ///

    /**
      * @notice Transfer `amount` tokens from `msg.sender` to `dst`
      * @param dst The address of the destination account
      * @param amount The number of tokens to transfer
      */
    function transfer(address dst, uint256 amount) external;

    ///
    /// !!!!!!!!!!!!!!
    /// !!! NOTICE !!! `transferFrom` does not return a value, in violation of the ERC-20 specification
    /// !!!!!!!!!!!!!!
    ///

    /**
      * @notice Transfer `amount` tokens from `src` to `dst`
      * @param src The address of the source account
      * @param dst The address of the destination account
      * @param amount The number of tokens to transfer
      */
    function transferFrom(address src, address dst, uint256 amount) external;

    /**
      * @notice Approve `spender` to transfer up to `amount` from `src`
      * @dev This will overwrite the approval amount for `spender`
      *  and is subject to issues noted [here](https://eips.ethereum.org/EIPS/eip-20#approve)
      * @param spender The address of the account which may transfer tokens
      * @param amount The number of tokens that are approved
      * @return Whether or not the approval succeeded
      */
    function approve(address spender, uint256 amount) external returns (bool success);

    /**
      * @notice Get the current allowance from `owner` for `spender`
      * @param owner The address of the account which owns the tokens to be spent
      * @param spender The address of the account which may transfer tokens
      * @return The number of tokens allowed to be spent
      */
    function allowance(address owner, address spender) external view returns (uint256 remaining);

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

// File: contracts/ATokenInterfaces.sol

pragma solidity ^0.5.16;




contract ATokenStorage {
    /**
     * @dev Guard variable for re-entrancy checks
     */
    bool internal _notEntered;

    /**
     * @notice EIP-20 token name for this token
     */
    string public name;

    /**
     * @notice EIP-20 token symbol for this token
     */
    string public symbol;

    /**
     * @notice EIP-20 token decimals for this token
     */
    uint8 public decimals;

    /**
     * @notice Maximum borrow rate that can ever be applied (.0005% / block)
     */

    uint internal constant borrowRateMaxMantissa = 0.0005e16;

    /**
     * @notice Maximum fraction of interest that can be set aside for reserves
     */
    uint internal constant reserveFactorMaxMantissa = 1e18;

    /**
     * @notice Administrator for this contract
     */
    address payable public admin;

    /**
     * @notice Pending administrator for this contract
     */
    address payable public pendingAdmin;

    /**
     * @notice Contract which oversees inter-aToken operations
     */
    ComptrollerInterface public comptroller;

    /**
     * @notice Model which tells what the current interest rate should be
     */
    InterestRateModel public interestRateModel;

    /**
     * @notice Initial exchange rate used when minting the first ATokens (used when totalSupply = 0)
     */
    uint internal initialExchangeRateMantissa;

    /**
     * @notice Fraction of interest currently set aside for reserves
     */
    uint public reserveFactorMantissa;

    /**
     * @notice Block number that interest was last accrued at
     */
    uint public accrualBlockNumber;

    /**
     * @notice Accumulator of the total earned interest rate since the opening of the market
     */
    uint public borrowIndex;

    /**
     * @notice Total amount of outstanding borrows of the underlying in this market
     */
    uint public totalBorrows;

    /**
     * @notice Total amount of reserves of the underlying held in this market
     */
    uint public totalReserves;

    /**
     * @notice Total number of tokens in circulation
     */
    uint public totalSupply;

    /**
     * @notice Official record of token balances for each account
     */
    mapping (address => uint) internal accountTokens;

    /**
     * @notice Approved token transfer amounts on behalf of others
     */
    mapping (address => mapping (address => uint)) internal transferAllowances;

    /**
     * @notice Container for borrow balance information
     * @member principal Total balance (with accrued interest), after applying the most recent balance-changing action
     * @member interestIndex Global borrowIndex as of the most recent balance-changing action
     */
    struct BorrowSnapshot {
        uint principal;
        uint interestIndex;
    }

    /**
     * @notice Mapping of account addresses to outstanding borrow balances
     */
    mapping(address => BorrowSnapshot) internal accountBorrows;

    /**
     * @notice Share of seized collateral that is added to reserves
     */
    uint public constant protocolSeizeShareMantissa = 5e16; //2.8%

}

contract ATokenInterface is ATokenStorage {
    /**
     * @notice Indicator that this is a AToken contract (for inspection)
     */
    bool public constant isAToken = true;


    /*** Market Events ***/

    /**
     * @notice Event emitted when interest is accrued
     */
    event AccrueInterest(uint cashPrior, uint interestAccumulated, uint borrowIndex, uint totalBorrows);

    /**
     * @notice Event emitted when tokens are minted
     */
    event Mint(address minter, uint mintAmount, uint mintTokens);

    /**
     * @notice Event emitted when tokens are redeemed
     */
    event Redeem(address redeemer, uint redeemAmount, uint redeemTokens);

    /**
     * @notice Event emitted when underlying is borrowed
     */
    event Borrow(address borrower, uint borrowAmount, uint accountBorrows, uint totalBorrows);

    /**
     * @notice Event emitted when a borrow is repaid
     */
    event RepayBorrow(address payer, address borrower, uint repayAmount, uint accountBorrows, uint totalBorrows);

    /**
     * @notice Event emitted when a borrow is liquidated
     */
    event LiquidateBorrow(address liquidator, address borrower, uint repayAmount, address aTokenCollateral, uint seizeTokens);


    /*** Admin Events ***/

    /**
     * @notice Event emitted when pendingAdmin is changed
     */
    event NewPendingAdmin(address oldPendingAdmin, address newPendingAdmin);

    /**
     * @notice Event emitted when pendingAdmin is accepted, which means admin is updated
     */
    event NewAdmin(address oldAdmin, address newAdmin);

    /**
     * @notice Event emitted when comptroller is changed
     */
    event NewComptroller(ComptrollerInterface oldComptroller, ComptrollerInterface newComptroller);

    /**
     * @notice Event emitted when interestRateModel is changed
     */
    event NewMarketInterestRateModel(InterestRateModel oldInterestRateModel, InterestRateModel newInterestRateModel);

    /**
     * @notice Event emitted when the reserve factor is changed
     */
    event NewReserveFactor(uint oldReserveFactorMantissa, uint newReserveFactorMantissa);

    /**
     * @notice Event emitted when the reserves are added
     */
    event ReservesAdded(address benefactor, uint addAmount, uint newTotalReserves);

    /**
     * @notice Event emitted when the reserves are reduced
     */
    event ReservesReduced(address admin, uint reduceAmount, uint newTotalReserves);

    /**
     * @notice EIP20 Transfer event
     */
    event Transfer(address indexed from, address indexed to, uint amount);

    /**
     * @notice EIP20 Approval event
     */
    event Approval(address indexed owner, address indexed spender, uint amount);

    /**
     * @notice Failure event
     */
    event Failure(uint error, uint info, uint detail);


    /*** User Interface ***/

    function transfer(address dst, uint amount) external returns (bool);
    function transferFrom(address src, address dst, uint amount) external returns (bool);
    function approve(address spender, uint amount) external returns (bool);
    function allowance(address owner, address spender) external view returns (uint);
    function balanceOf(address owner) external view returns (uint);
    function balanceOfUnderlying(address owner) external returns (uint);
    function getAccountSnapshot(address account) external view returns (uint, uint, uint, uint);
    function borrowRatePerBlock() external view returns (uint);
    function supplyRatePerBlock() external view returns (uint);
    function totalBorrowsCurrent() external returns (uint);
    function borrowBalanceCurrent(address account) external returns (uint);
    function borrowBalanceStored(address account) public view returns (uint);
    function exchangeRateCurrent() public returns (uint);
    function exchangeRateStored() public view returns (uint);
    function getCash() external view returns (uint);
    function accrueInterest() public returns (uint);
    function seize(address liquidator, address borrower, uint seizeTokens) external returns (uint);


    /*** Admin Functions ***/

    function _setPendingAdmin(address payable newPendingAdmin) external returns (uint);
    function _acceptAdmin() external returns (uint);
    function _setComptroller(ComptrollerInterface newComptroller) public returns (uint);
    function _setReserveFactor(uint newReserveFactorMantissa) external returns (uint);
    function _reduceReserves(uint reduceAmount) external returns (uint);
    function _setInterestRateModel(InterestRateModel newInterestRateModel) public returns (uint);
}

contract AErc20Storage {
    /**
     * @notice Underlying asset for this AToken
     */
    address public underlying;
}

contract AErc20Interface is AErc20Storage {

    /*** User Interface ***/

    function mint(uint mintAmount) external returns (uint);
    function redeem(uint redeemTokens) external returns (uint);
    function redeemUnderlying(uint redeemAmount) external returns (uint);
    function borrow(uint borrowAmount) external returns (uint);
    function repayBorrow(uint repayAmount) external returns (uint);
    function repayBorrowBehalf(address borrower, uint repayAmount) external returns (uint);
    function liquidateBorrow(address borrower, uint repayAmount, ATokenInterface aTokenCollateral) external returns (uint);
    function sweepToken(EIP20NonStandardInterface token) external;


    /*** Admin Functions ***/

    function _addReserves(uint addAmount) external returns (uint);
}

contract CDelegationStorage {
    /**
     * @notice Implementation address for this contract
     */
    address public implementation;
}

contract CDelegatorInterface is CDelegationStorage {
    /**
     * @notice Emitted when implementation is changed
     */
    event NewImplementation(address oldImplementation, address newImplementation);

    /**
     * @notice Called by the admin to update the implementation of the delegator
     * @param implementation_ The address of the new implementation for delegation
     * @param allowResign Flag to indicate whether to call _resignImplementation on the old implementation
     * @param becomeImplementationData The encoded bytes data to be passed to _becomeImplementation
     */
    function _setImplementation(address implementation_, bool allowResign, bytes memory becomeImplementationData) public;
}

contract ADelegateInterface is CDelegationStorage {
    /**
     * @notice Called by the delegator on a delegate to initialize it for duty
     * @dev Should revert if any issues arise which make it unfit for delegation
     * @param data The encoded bytes data for any initialization
     */
    function _becomeImplementation(bytes memory data) public;

    /**
     * @notice Called by the delegator on a delegate to forfeit its responsibility
     */
    function _resignImplementation() public;
}

// File: contracts/ErrorReporter.sol

pragma solidity ^0.5.16;

contract ComptrollerErrorReporter {
    enum Error {
        NO_ERROR,
        UNAUTHORIZED,
        COMPTROLLER_MISMATCH,
        INSUFFICIENT_SHORTFALL,
        INSUFFICIENT_LIQUIDITY,
        INVALID_CLOSE_FACTOR,
        INVALID_COLLATERAL_FACTOR,
        INVALID_LIQUIDATION_INCENTIVE,
        MARKET_NOT_ENTERED, // no longer possible
        MARKET_NOT_LISTED,
        MARKET_ALREADY_LISTED,
        MATH_ERROR,
        NONZERO_BORROW_BALANCE,
        PRICE_ERROR,
        REJECTION,
        SNAPSHOT_ERROR,
        TOO_MANY_ASSETS,
        TOO_MUCH_REPAY
    }

    enum FailureInfo {
        ACCEPT_ADMIN_PENDING_ADMIN_CHECK,
        ACCEPT_PENDING_IMPLEMENTATION_ADDRESS_CHECK,
        EXIT_MARKET_BALANCE_OWED,
        EXIT_MARKET_REJECTION,
        SET_CLOSE_FACTOR_OWNER_CHECK,
        SET_CLOSE_FACTOR_VALIDATION,
        SET_COLLATERAL_FACTOR_OWNER_CHECK,
        SET_COLLATERAL_FACTOR_NO_EXISTS,
        SET_COLLATERAL_FACTOR_VALIDATION,
        SET_COLLATERAL_FACTOR_WITHOUT_PRICE,
        SET_IMPLEMENTATION_OWNER_CHECK,
        SET_LIQUIDATION_INCENTIVE_OWNER_CHECK,
        SET_LIQUIDATION_INCENTIVE_VALIDATION,
        SET_MAX_ASSETS_OWNER_CHECK,
        SET_PENDING_ADMIN_OWNER_CHECK,
        SET_PENDING_IMPLEMENTATION_OWNER_CHECK,
        SET_PRICE_ORACLE_OWNER_CHECK,
        SUPPORT_MARKET_EXISTS,
        SUPPORT_MARKET_OWNER_CHECK,
        SET_PAUSE_GUARDIAN_OWNER_CHECK
    }

    /**
      * @dev `error` corresponds to enum Error; `info` corresponds to enum FailureInfo, and `detail` is an arbitrary
      * contract-specific code that enables us to report opaque error codes from upgradeable contracts.
      **/
    event Failure(uint error, uint info, uint detail);

    /**
      * @dev use this when reporting a known error from the money market or a non-upgradeable collaborator
      */
    function fail(Error err, FailureInfo info) internal returns (uint) {
        emit Failure(uint(err), uint(info), 0);

        return uint(err);
    }

    /**
      * @dev use this when reporting an opaque error from an upgradeable collaborator contract
      */
    function failOpaque(Error err, FailureInfo info, uint opaqueError) internal returns (uint) {
        emit Failure(uint(err), uint(info), opaqueError);

        return uint(err);
    }
}

contract TokenErrorReporter {
    enum Error {
        NO_ERROR,
        UNAUTHORIZED,
        BAD_INPUT,
        COMPTROLLER_REJECTION,
        COMPTROLLER_CALCULATION_ERROR,
        INTEREST_RATE_MODEL_ERROR,
        INVALID_ACCOUNT_PAIR,
        INVALID_CLOSE_AMOUNT_REQUESTED,
        INVALID_COLLATERAL_FACTOR,
        MATH_ERROR,
        MARKET_NOT_FRESH,
        MARKET_NOT_LISTED,
        TOKEN_INSUFFICIENT_ALLOWANCE,
        TOKEN_INSUFFICIENT_BALANCE,
        TOKEN_INSUFFICIENT_CASH,
        TOKEN_TRANSFER_IN_FAILED,
        TOKEN_TRANSFER_OUT_FAILED
    }

    /*
     * Note: FailureInfo (but not Error) is kept in alphabetical order
     *       This is because FailureInfo grows significantly faster, and
     *       the order of Error has some meaning, while the order of FailureInfo
     *       is entirely arbitrary.
     */
    enum FailureInfo {
        ACCEPT_ADMIN_PENDING_ADMIN_CHECK,
        ACCRUE_INTEREST_ACCUMULATED_INTEREST_CALCULATION_FAILED,
        ACCRUE_INTEREST_BORROW_RATE_CALCULATION_FAILED,
        ACCRUE_INTEREST_NEW_BORROW_INDEX_CALCULATION_FAILED,
        ACCRUE_INTEREST_NEW_TOTAL_BORROWS_CALCULATION_FAILED,
        ACCRUE_INTEREST_NEW_TOTAL_RESERVES_CALCULATION_FAILED,
        ACCRUE_INTEREST_SIMPLE_INTEREST_FACTOR_CALCULATION_FAILED,
        BORROW_ACCUMULATED_BALANCE_CALCULATION_FAILED,
        BORROW_ACCRUE_INTEREST_FAILED,
        BORROW_CASH_NOT_AVAILABLE,
        BORROW_FRESHNESS_CHECK,
        BORROW_NEW_TOTAL_BALANCE_CALCULATION_FAILED,
        BORROW_NEW_ACCOUNT_BORROW_BALANCE_CALCULATION_FAILED,
        BORROW_MARKET_NOT_LISTED,
        BORROW_COMPTROLLER_REJECTION,
        LIQUIDATE_ACCRUE_BORROW_INTEREST_FAILED,
        LIQUIDATE_ACCRUE_COLLATERAL_INTEREST_FAILED,
        LIQUIDATE_COLLATERAL_FRESHNESS_CHECK,
        LIQUIDATE_COMPTROLLER_REJECTION,
        LIQUIDATE_COMPTROLLER_CALCULATE_AMOUNT_SEIZE_FAILED,
        LIQUIDATE_CLOSE_AMOUNT_IS_UINT_MAX,
        LIQUIDATE_CLOSE_AMOUNT_IS_ZERO,
        LIQUIDATE_FRESHNESS_CHECK,
        LIQUIDATE_LIQUIDATOR_IS_BORROWER,
        LIQUIDATE_REPAY_BORROW_FRESH_FAILED,
        LIQUIDATE_SEIZE_BALANCE_INCREMENT_FAILED,
        LIQUIDATE_SEIZE_BALANCE_DECREMENT_FAILED,
        LIQUIDATE_SEIZE_COMPTROLLER_REJECTION,
        LIQUIDATE_SEIZE_LIQUIDATOR_IS_BORROWER,
        LIQUIDATE_SEIZE_TOO_MUCH,
        MINT_ACCRUE_INTEREST_FAILED,
        MINT_COMPTROLLER_REJECTION,
        MINT_EXCHANGE_CALCULATION_FAILED,
        MINT_EXCHANGE_RATE_READ_FAILED,
        MINT_FRESHNESS_CHECK,
        MINT_NEW_ACCOUNT_BALANCE_CALCULATION_FAILED,
        MINT_NEW_TOTAL_SUPPLY_CALCULATION_FAILED,
        MINT_TRANSFER_IN_FAILED,
        MINT_TRANSFER_IN_NOT_POSSIBLE,
        REDEEM_ACCRUE_INTEREST_FAILED,
        REDEEM_COMPTROLLER_REJECTION,
        REDEEM_EXCHANGE_TOKENS_CALCULATION_FAILED,
        REDEEM_EXCHANGE_AMOUNT_CALCULATION_FAILED,
        REDEEM_EXCHANGE_RATE_READ_FAILED,
        REDEEM_FRESHNESS_CHECK,
        REDEEM_NEW_ACCOUNT_BALANCE_CALCULATION_FAILED,
        REDEEM_NEW_TOTAL_SUPPLY_CALCULATION_FAILED,
        REDEEM_TRANSFER_OUT_NOT_POSSIBLE,
        REDUCE_RESERVES_ACCRUE_INTEREST_FAILED,
        REDUCE_RESERVES_ADMIN_CHECK,
        REDUCE_RESERVES_CASH_NOT_AVAILABLE,
        REDUCE_RESERVES_FRESH_CHECK,
        REDUCE_RESERVES_VALIDATION,
        REPAY_BEHALF_ACCRUE_INTEREST_FAILED,
        REPAY_BORROW_ACCRUE_INTEREST_FAILED,
        REPAY_BORROW_ACCUMULATED_BALANCE_CALCULATION_FAILED,
        REPAY_BORROW_COMPTROLLER_REJECTION,
        REPAY_BORROW_FRESHNESS_CHECK,
        REPAY_BORROW_NEW_ACCOUNT_BORROW_BALANCE_CALCULATION_FAILED,
        REPAY_BORROW_NEW_TOTAL_BALANCE_CALCULATION_FAILED,
        REPAY_BORROW_TRANSFER_IN_NOT_POSSIBLE,
        SET_COLLATERAL_FACTOR_OWNER_CHECK,
        SET_COLLATERAL_FACTOR_VALIDATION,
        SET_COMPTROLLER_OWNER_CHECK,
        SET_INTEREST_RATE_MODEL_ACCRUE_INTEREST_FAILED,
        SET_INTEREST_RATE_MODEL_FRESH_CHECK,
        SET_INTEREST_RATE_MODEL_OWNER_CHECK,
        SET_MAX_ASSETS_OWNER_CHECK,
        SET_ORACLE_MARKET_NOT_LISTED,
        SET_PENDING_ADMIN_OWNER_CHECK,
        SET_RESERVE_FACTOR_ACCRUE_INTEREST_FAILED,
        SET_RESERVE_FACTOR_ADMIN_CHECK,
        SET_RESERVE_FACTOR_FRESH_CHECK,
        SET_RESERVE_FACTOR_BOUNDS_CHECK,
        TRANSFER_COMPTROLLER_REJECTION,
        TRANSFER_NOT_ALLOWED,
        TRANSFER_NOT_ENOUGH,
        TRANSFER_TOO_MUCH,
        ADD_RESERVES_ACCRUE_INTEREST_FAILED,
        ADD_RESERVES_FRESH_CHECK,
        ADD_RESERVES_TRANSFER_IN_NOT_POSSIBLE
    }

    /**
      * @dev `error` corresponds to enum Error; `info` corresponds to enum FailureInfo, and `detail` is an arbitrary
      * contract-specific code that enables us to report opaque error codes from upgradeable contracts.
      **/
    event Failure(uint error, uint info, uint detail);

    /**
      * @dev use this when reporting a known error from the money market or a non-upgradeable collaborator
      */
    function fail(Error err, FailureInfo info) internal returns (uint) {
        emit Failure(uint(err), uint(info), 0);

        return uint(err);
    }

    /**
      * @dev use this when reporting an opaque error from an upgradeable collaborator contract
      */
    function failOpaque(Error err, FailureInfo info, uint opaqueError) internal returns (uint) {
        emit Failure(uint(err), uint(info), opaqueError);

        return uint(err);
    }
}

// File: contracts/CarefulMath.sol

pragma solidity ^0.5.16;

/**
  * @title Careful Math
  * @author Aquarius
  * @notice Derived from OpenZeppelin's SafeMath library
  *         https://github.com/OpenZeppelin/openzeppelin-solidity/blob/master/contracts/math/SafeMath.sol
  */
contract CarefulMath {

    /**
     * @dev Possible error codes that we can return
     */
    enum MathError {
        NO_ERROR,
        DIVISION_BY_ZERO,
        INTEGER_OVERFLOW,
        INTEGER_UNDERFLOW
    }

    /**
    * @dev Multiplies two numbers, returns an error on overflow.
    */
    function mulUInt(uint a, uint b) internal pure returns (MathError, uint) {
        if (a == 0) {
            return (MathError.NO_ERROR, 0);
        }

        uint c = a * b;

        if (c / a != b) {
            return (MathError.INTEGER_OVERFLOW, 0);
        } else {
            return (MathError.NO_ERROR, c);
        }
    }

    /**
    * @dev Integer division of two numbers, truncating the quotient.
    */
    function divUInt(uint a, uint b) internal pure returns (MathError, uint) {
        if (b == 0) {
            return (MathError.DIVISION_BY_ZERO, 0);
        }

        return (MathError.NO_ERROR, a / b);
    }

    /**
    * @dev Subtracts two numbers, returns an error on overflow (i.e. if subtrahend is greater than minuend).
    */
    function subUInt(uint a, uint b) internal pure returns (MathError, uint) {
        if (b <= a) {
            return (MathError.NO_ERROR, a - b);
        } else {
            return (MathError.INTEGER_UNDERFLOW, 0);
        }
    }

    /**
    * @dev Adds two numbers, returns an error on overflow.
    */
    function addUInt(uint a, uint b) internal pure returns (MathError, uint) {
        uint c = a + b;

        if (c >= a) {
            return (MathError.NO_ERROR, c);
        } else {
            return (MathError.INTEGER_OVERFLOW, 0);
        }
    }

    /**
    * @dev add a and b and then subtract c
    */
    function addThenSubUInt(uint a, uint b, uint c) internal pure returns (MathError, uint) {
        (MathError err0, uint sum) = addUInt(a, b);

        if (err0 != MathError.NO_ERROR) {
            return (err0, 0);
        }

        return subUInt(sum, c);
    }
}

// File: contracts/ExponentialNoError.sol

pragma solidity ^0.5.16;

/**
 * @title Exponential module for storing fixed-precision decimals
 * @author Aquarius
 * @notice Exp is a struct which stores decimals with a fixed precision of 18 decimal places.
 *         Thus, if we wanted to store the 5.1, mantissa would store 5.1e18. That is:
 *         `Exp({mantissa: 5100000000000000000})`.
 */
contract ExponentialNoError {
    uint constant expScale = 1e18;
    uint constant doubleScale = 1e36;
    uint constant halfExpScale = expScale/2;
    uint constant mantissaOne = expScale;

    struct Exp {
        uint mantissa;
    }

    struct Double {
        uint mantissa;
    }

    /**
     * @dev Truncates the given exp to a whole number value.
     *      For example, truncate(Exp{mantissa: 15 * expScale}) = 15
     */
    function truncate(Exp memory exp) pure internal returns (uint) {
        // Note: We are not using careful math here as we're performing a division that cannot fail
        return exp.mantissa / expScale;
    }

    /**
     * @dev Multiply an Exp by a scalar, then truncate to return an unsigned integer.
     */
    function mul_ScalarTruncate(Exp memory a, uint scalar) pure internal returns (uint) {
        Exp memory product = mul_(a, scalar);
        return truncate(product);
    }

    /**
     * @dev Multiply an Exp by a scalar, truncate, then add an to an unsigned integer, returning an unsigned integer.
     */
    function mul_ScalarTruncateAddUInt(Exp memory a, uint scalar, uint addend) pure internal returns (uint) {
        Exp memory product = mul_(a, scalar);
        return add_(truncate(product), addend);
    }

    /**
     * @dev Checks if first Exp is less than second Exp.
     */
    function lessThanExp(Exp memory left, Exp memory right) pure internal returns (bool) {
        return left.mantissa < right.mantissa;
    }

    /**
     * @dev Checks if left Exp <= right Exp.
     */
    function lessThanOrEqualExp(Exp memory left, Exp memory right) pure internal returns (bool) {
        return left.mantissa <= right.mantissa;
    }

    /**
     * @dev Checks if left Exp > right Exp.
     */
    function greaterThanExp(Exp memory left, Exp memory right) pure internal returns (bool) {
        return left.mantissa > right.mantissa;
    }

    /**
     * @dev returns true if Exp is exactly zero
     */
    function isZeroExp(Exp memory value) pure internal returns (bool) {
        return value.mantissa == 0;
    }

    function safe224(uint n, string memory errorMessage) pure internal returns (uint224) {
        require(n < 2**224, errorMessage);
        return uint224(n);
    }

    function safe32(uint n, string memory errorMessage) pure internal returns (uint32) {
        require(n < 2**32, errorMessage);
        return uint32(n);
    }

    function add_(Exp memory a, Exp memory b) pure internal returns (Exp memory) {
        return Exp({mantissa: add_(a.mantissa, b.mantissa)});
    }

    function add_(Double memory a, Double memory b) pure internal returns (Double memory) {
        return Double({mantissa: add_(a.mantissa, b.mantissa)});
    }

    function add_(uint a, uint b) pure internal returns (uint) {
        return add_(a, b, "addition overflow");
    }

    function add_(uint a, uint b, string memory errorMessage) pure internal returns (uint) {
        uint c = a + b;
        require(c >= a, errorMessage);
        return c;
    }

    function sub_(Exp memory a, Exp memory b) pure internal returns (Exp memory) {
        return Exp({mantissa: sub_(a.mantissa, b.mantissa)});
    }

    function sub_(Double memory a, Double memory b) pure internal returns (Double memory) {
        return Double({mantissa: sub_(a.mantissa, b.mantissa)});
    }

    function sub_(uint a, uint b) pure internal returns (uint) {
        return sub_(a, b, "subtraction underflow");
    }

    function sub_(uint a, uint b, string memory errorMessage) pure internal returns (uint) {
        require(b <= a, errorMessage);
        return a - b;
    }

    function mul_(Exp memory a, Exp memory b) pure internal returns (Exp memory) {
        return Exp({mantissa: mul_(a.mantissa, b.mantissa) / expScale});
    }

    function mul_(Exp memory a, uint b) pure internal returns (Exp memory) {
        return Exp({mantissa: mul_(a.mantissa, b)});
    }

    function mul_(uint a, Exp memory b) pure internal returns (uint) {
        return mul_(a, b.mantissa) / expScale;
    }

    function mul_(Double memory a, Double memory b) pure internal returns (Double memory) {
        return Double({mantissa: mul_(a.mantissa, b.mantissa) / doubleScale});
    }

    function mul_(Double memory a, uint b) pure internal returns (Double memory) {
        return Double({mantissa: mul_(a.mantissa, b)});
    }

    function mul_(uint a, Double memory b) pure internal returns (uint) {
        return mul_(a, b.mantissa) / doubleScale;
    }

    function mul_(uint a, uint b) pure internal returns (uint) {
        return mul_(a, b, "multiplication overflow");
    }

    function mul_(uint a, uint b, string memory errorMessage) pure internal returns (uint) {
        if (a == 0 || b == 0) {
            return 0;
        }
        uint c = a * b;
        require(c / a == b, errorMessage);
        return c;
    }

    function div_(Exp memory a, Exp memory b) pure internal returns (Exp memory) {
        return Exp({mantissa: div_(mul_(a.mantissa, expScale), b.mantissa)});
    }

    function div_(Exp memory a, uint b) pure internal returns (Exp memory) {
        return Exp({mantissa: div_(a.mantissa, b)});
    }

    function div_(uint a, Exp memory b) pure internal returns (uint) {
        return div_(mul_(a, expScale), b.mantissa);
    }

    function div_(Double memory a, Double memory b) pure internal returns (Double memory) {
        return Double({mantissa: div_(mul_(a.mantissa, doubleScale), b.mantissa)});
    }

    function div_(Double memory a, uint b) pure internal returns (Double memory) {
        return Double({mantissa: div_(a.mantissa, b)});
    }

    function div_(uint a, Double memory b) pure internal returns (uint) {
        return div_(mul_(a, doubleScale), b.mantissa);
    }

    function div_(uint a, uint b) pure internal returns (uint) {
        return div_(a, b, "divide by zero");
    }

    function div_(uint a, uint b, string memory errorMessage) pure internal returns (uint) {
        require(b > 0, errorMessage);
        return a / b;
    }

    function fraction(uint a, uint b) pure internal returns (Double memory) {
        return Double({mantissa: div_(mul_(a, doubleScale), b)});
    }
}

// File: contracts/Exponential.sol

pragma solidity ^0.5.16;



/**
 * @title Exponential module for storing fixed-precision decimals
 * @author Aquarius
 * @dev Legacy contract for compatibility reasons with existing contracts that still use MathError
 * @notice Exp is a struct which stores decimals with a fixed precision of 18 decimal places.
 *         Thus, if we wanted to store the 5.1, mantissa would store 5.1e18. That is:
 *         `Exp({mantissa: 5100000000000000000})`.
 */
contract Exponential is CarefulMath, ExponentialNoError {
    /**
     * @dev Creates an exponential from numerator and denominator values.
     *      Note: Returns an error if (`num` * 10e18) > MAX_INT,
     *            or if `denom` is zero.
     */
    function getExp(uint num, uint denom) pure internal returns (MathError, Exp memory) {
        (MathError err0, uint scaledNumerator) = mulUInt(num, expScale);
        if (err0 != MathError.NO_ERROR) {
            return (err0, Exp({mantissa: 0}));
        }

        (MathError err1, uint rational) = divUInt(scaledNumerator, denom);
        if (err1 != MathError.NO_ERROR) {
            return (err1, Exp({mantissa: 0}));
        }

        return (MathError.NO_ERROR, Exp({mantissa: rational}));
    }

    /**
     * @dev Adds two exponentials, returning a new exponential.
     */
    function addExp(Exp memory a, Exp memory b) pure internal returns (MathError, Exp memory) {
        (MathError error, uint result) = addUInt(a.mantissa, b.mantissa);

        return (error, Exp({mantissa: result}));
    }

    /**
     * @dev Subtracts two exponentials, returning a new exponential.
     */
    function subExp(Exp memory a, Exp memory b) pure internal returns (MathError, Exp memory) {
        (MathError error, uint result) = subUInt(a.mantissa, b.mantissa);

        return (error, Exp({mantissa: result}));
    }

    /**
     * @dev Multiply an Exp by a scalar, returning a new Exp.
     */
    function mulScalar(Exp memory a, uint scalar) pure internal returns (MathError, Exp memory) {
        (MathError err0, uint scaledMantissa) = mulUInt(a.mantissa, scalar);
        if (err0 != MathError.NO_ERROR) {
            return (err0, Exp({mantissa: 0}));
        }

        return (MathError.NO_ERROR, Exp({mantissa: scaledMantissa}));
    }

    /**
     * @dev Multiply an Exp by a scalar, then truncate to return an unsigned integer.
     */
    function mulScalarTruncate(Exp memory a, uint scalar) pure internal returns (MathError, uint) {
        (MathError err, Exp memory product) = mulScalar(a, scalar);
        if (err != MathError.NO_ERROR) {
            return (err, 0);
        }

        return (MathError.NO_ERROR, truncate(product));
    }

    /**
     * @dev Multiply an Exp by a scalar, truncate, then add an to an unsigned integer, returning an unsigned integer.
     */
    function mulScalarTruncateAddUInt(Exp memory a, uint scalar, uint addend) pure internal returns (MathError, uint) {
        (MathError err, Exp memory product) = mulScalar(a, scalar);
        if (err != MathError.NO_ERROR) {
            return (err, 0);
        }

        return addUInt(truncate(product), addend);
    }

    /**
     * @dev Divide an Exp by a scalar, returning a new Exp.
     */
    function divScalar(Exp memory a, uint scalar) pure internal returns (MathError, Exp memory) {
        (MathError err0, uint descaledMantissa) = divUInt(a.mantissa, scalar);
        if (err0 != MathError.NO_ERROR) {
            return (err0, Exp({mantissa: 0}));
        }

        return (MathError.NO_ERROR, Exp({mantissa: descaledMantissa}));
    }

    /**
     * @dev Divide a scalar by an Exp, returning a new Exp.
     */
    function divScalarByExp(uint scalar, Exp memory divisor) pure internal returns (MathError, Exp memory) {
        /*
          We are doing this as:
          getExp(mulUInt(expScale, scalar), divisor.mantissa)

          How it works:
          Exp = a / b;
          Scalar = s;
          `s / (a / b)` = `b * s / a` and since for an Exp `a = mantissa, b = expScale`
        */
        (MathError err0, uint numerator) = mulUInt(expScale, scalar);
        if (err0 != MathError.NO_ERROR) {
            return (err0, Exp({mantissa: 0}));
        }
        return getExp(numerator, divisor.mantissa);
    }

    /**
     * @dev Divide a scalar by an Exp, then truncate to return an unsigned integer.
     */
    function divScalarByExpTruncate(uint scalar, Exp memory divisor) pure internal returns (MathError, uint) {
        (MathError err, Exp memory fraction) = divScalarByExp(scalar, divisor);
        if (err != MathError.NO_ERROR) {
            return (err, 0);
        }

        return (MathError.NO_ERROR, truncate(fraction));
    }

    /**
     * @dev Multiplies two exponentials, returning a new exponential.
     */
    function mulExp(Exp memory a, Exp memory b) pure internal returns (MathError, Exp memory) {

        (MathError err0, uint doubleScaledProduct) = mulUInt(a.mantissa, b.mantissa);
        if (err0 != MathError.NO_ERROR) {
            return (err0, Exp({mantissa: 0}));
        }

        // We add half the scale before dividing so that we get rounding instead of truncation.
        //  See "Listing 6" and text above it at https://accu.org/index.php/journals/1717
        // Without this change, a result like 6.6...e-19 will be truncated to 0 instead of being rounded to 1e-18.
        (MathError err1, uint doubleScaledProductWithHalfScale) = addUInt(halfExpScale, doubleScaledProduct);
        if (err1 != MathError.NO_ERROR) {
            return (err1, Exp({mantissa: 0}));
        }

        (MathError err2, uint product) = divUInt(doubleScaledProductWithHalfScale, expScale);
        // The only error `div` can return is MathError.DIVISION_BY_ZERO but we control `expScale` and it is not zero.
        assert(err2 == MathError.NO_ERROR);

        return (MathError.NO_ERROR, Exp({mantissa: product}));
    }

    /**
     * @dev Multiplies two exponentials given their mantissas, returning a new exponential.
     */
    function mulExp(uint a, uint b) pure internal returns (MathError, Exp memory) {
        return mulExp(Exp({mantissa: a}), Exp({mantissa: b}));
    }

    /**
     * @dev Multiplies three exponentials, returning a new exponential.
     */
    function mulExp3(Exp memory a, Exp memory b, Exp memory c) pure internal returns (MathError, Exp memory) {
        (MathError err, Exp memory ab) = mulExp(a, b);
        if (err != MathError.NO_ERROR) {
            return (err, ab);
        }
        return mulExp(ab, c);
    }

    /**
     * @dev Divides two exponentials, returning a new exponential.
     *     (a/scale) / (b/scale) = (a/scale) * (scale/b) = a/b,
     *  which we can scale as an Exp by calling getExp(a.mantissa, b.mantissa)
     */
    function divExp(Exp memory a, Exp memory b) pure internal returns (MathError, Exp memory) {
        return getExp(a.mantissa, b.mantissa);
    }
}

// File: contracts/EIP20Interface.sol

pragma solidity ^0.5.16;

/**
 * @title ERC 20 Token Standard Interface
 *  https://eips.ethereum.org/EIPS/eip-20
 */
interface EIP20Interface {
    function name() external view returns (string memory);
    function symbol() external view returns (string memory);
    function decimals() external view returns (uint8);

    /**
      * @notice Get the total number of tokens in circulation
      * @return The supply of tokens
      */
    function totalSupply() external view returns (uint256);

    /**
     * @notice Gets the balance of the specified address
     * @param owner The address from which the balance will be retrieved
     * @return The balance
     */
    function balanceOf(address owner) external view returns (uint256 balance);

    /**
      * @notice Transfer `amount` tokens from `msg.sender` to `dst`
      * @param dst The address of the destination account
      * @param amount The number of tokens to transfer
      * @return Whether or not the transfer succeeded
      */
    function transfer(address dst, uint256 amount) external returns (bool success);

    /**
      * @notice Transfer `amount` tokens from `src` to `dst`
      * @param src The address of the source account
      * @param dst The address of the destination account
      * @param amount The number of tokens to transfer
      * @return Whether or not the transfer succeeded
      */
    function transferFrom(address src, address dst, uint256 amount) external returns (bool success);

    /**
      * @notice Approve `spender` to transfer up to `amount` from `src`
      * @dev This will overwrite the approval amount for `spender`
      *  and is subject to issues noted [here](https://eips.ethereum.org/EIPS/eip-20#approve)
      * @param spender The address of the account which may transfer tokens
      * @param amount The number of tokens that are approved (-1 means infinite)
      * @return Whether or not the approval succeeded
      */
    function approve(address spender, uint256 amount) external returns (bool success);

    /**
      * @notice Get the current allowance from `owner` for `spender`
      * @param owner The address of the account which owns the tokens to be spent
      * @param spender The address of the account which may transfer tokens
      * @return The number of tokens allowed to be spent (-1 means infinite)
      */
    function allowance(address owner, address spender) external view returns (uint256 remaining);

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

// File: contracts/AToken.sol

pragma solidity ^0.5.16;







/**
 * @title Aquarius's AToken Contract
 * @notice Abstract base for ATokens
 * @author Aquarius
 */
contract AToken is ATokenInterface, Exponential, TokenErrorReporter {
    /**
     * @notice Initialize the money market
     * @param comptroller_ The address of the Comptroller
     * @param interestRateModel_ The address of the interest rate model
     * @param initialExchangeRateMantissa_ The initial exchange rate, scaled by 1e18
     * @param name_ EIP-20 name of this token
     * @param symbol_ EIP-20 symbol of this token
     * @param decimals_ EIP-20 decimal precision of this token
     */
    function initialize(ComptrollerInterface comptroller_,
                        InterestRateModel interestRateModel_,
                        uint initialExchangeRateMantissa_,
                        string memory name_,
                        string memory symbol_,
                        uint8 decimals_) public {
        require(msg.sender == admin, "only admin may initialize the market");
        require(accrualBlockNumber == 0 && borrowIndex == 0, "market may only be initialized once");

        // Set initial exchange rate
        initialExchangeRateMantissa = initialExchangeRateMantissa_;
        require(initialExchangeRateMantissa > 0, "initial exchange rate must be greater than zero.");

        // Set the comptroller
        uint err = _setComptroller(comptroller_);
        require(err == uint(Error.NO_ERROR), "setting comptroller failed");

        // Initialize block number and borrow index (block number mocks depend on comptroller being set)
        accrualBlockNumber = getBlockNumber();
        borrowIndex = mantissaOne;

        // Set the interest rate model (depends on block number / borrow index)
        err = _setInterestRateModelFresh(interestRateModel_);
        require(err == uint(Error.NO_ERROR), "setting interest rate model failed");

        name = name_;
        symbol = symbol_;
        decimals = decimals_;

        // The counter starts true to prevent changing it from zero to non-zero (i.e. smaller cost/refund)
        _notEntered = true;
    }

    /**
     * @notice Transfer `tokens` tokens from `src` to `dst` by `spender`
     * @dev Called by both `transfer` and `transferFrom` internally
     * @param spender The address of the account performing the transfer
     * @param src The address of the source account
     * @param dst The address of the destination account
     * @param tokens The number of tokens to transfer
     * @return Whether or not the transfer succeeded
     */
    function transferTokens(address spender, address src, address dst, uint tokens) internal returns (uint) {
        /* Fail if transfer not allowed */
        uint allowed = comptroller.transferAllowed(address(this), src, dst, tokens);
        if (allowed != 0) {
            return failOpaque(Error.COMPTROLLER_REJECTION, FailureInfo.TRANSFER_COMPTROLLER_REJECTION, allowed);
        }

        /* Do not allow self-transfers */
        if (src == dst) {
            return fail(Error.BAD_INPUT, FailureInfo.TRANSFER_NOT_ALLOWED);
        }

        /* Get the allowance, infinite for the account owner */
        uint startingAllowance = 0;
        if (spender == src) {
            startingAllowance = uint(-1);
        } else {
            startingAllowance = transferAllowances[src][spender];
        }

        /* Do the calculations, checking for {under,over}flow */
        MathError mathErr;
        uint allowanceNew;
        uint sraTokensNew;
        uint dstTokensNew;

        (mathErr, allowanceNew) = subUInt(startingAllowance, tokens);
        if (mathErr != MathError.NO_ERROR) {
            return fail(Error.MATH_ERROR, FailureInfo.TRANSFER_NOT_ALLOWED);
        }

        (mathErr, sraTokensNew) = subUInt(accountTokens[src], tokens);
        if (mathErr != MathError.NO_ERROR) {
            return fail(Error.MATH_ERROR, FailureInfo.TRANSFER_NOT_ENOUGH);
        }

        (mathErr, dstTokensNew) = addUInt(accountTokens[dst], tokens);
        if (mathErr != MathError.NO_ERROR) {
            return fail(Error.MATH_ERROR, FailureInfo.TRANSFER_TOO_MUCH);
        }

        /////////////////////////
        // EFFECTS & INTERACTIONS
        // (No safe failures beyond this point)

        accountTokens[src] = sraTokensNew;
        accountTokens[dst] = dstTokensNew;

        /* Eat some of the allowance (if necessary) */
        if (startingAllowance != uint(-1)) {
            transferAllowances[src][spender] = allowanceNew;
        }

        /* We emit a Transfer event */
        emit Transfer(src, dst, tokens);

        // unused function
        // comptroller.transferVerify(address(this), src, dst, tokens);

        return uint(Error.NO_ERROR);
    }

    /**
     * @notice Transfer `amount` tokens from `msg.sender` to `dst`
     * @param dst The address of the destination account
     * @param amount The number of tokens to transfer
     * @return Whether or not the transfer succeeded
     */
    function transfer(address dst, uint256 amount) external nonReentrant returns (bool) {
        return transferTokens(msg.sender, msg.sender, dst, amount) == uint(Error.NO_ERROR);
    }

    /**
     * @notice Transfer `amount` tokens from `src` to `dst`
     * @param src The address of the source account
     * @param dst The address of the destination account
     * @param amount The number of tokens to transfer
     * @return Whether or not the transfer succeeded
     */
    function transferFrom(address src, address dst, uint256 amount) external nonReentrant returns (bool) {
        return transferTokens(msg.sender, src, dst, amount) == uint(Error.NO_ERROR);
    }

    /**
     * @notice Approve `spender` to transfer up to `amount` from `src`
     * @dev This will overwrite the approval amount for `spender`
     *  and is subject to issues noted [here](https://eips.ethereum.org/EIPS/eip-20#approve)
     * @param spender The address of the account which may transfer tokens
     * @param amount The number of tokens that are approved (-1 means infinite)
     * @return Whether or not the approval succeeded
     */
    function approve(address spender, uint256 amount) external returns (bool) {
        address src = msg.sender;
        transferAllowances[src][spender] = amount;
        emit Approval(src, spender, amount);
        return true;
    }

    /**
     * @notice Get the current allowance from `owner` for `spender`
     * @param owner The address of the account which owns the tokens to be spent
     * @param spender The address of the account which may transfer tokens
     * @return The number of tokens allowed to be spent (-1 means infinite)
     */
    function allowance(address owner, address spender) external view returns (uint256) {
        return transferAllowances[owner][spender];
    }

    /**
     * @notice Get the token balance of the `owner`
     * @param owner The address of the account to query
     * @return The number of tokens owned by `owner`
     */
    function balanceOf(address owner) external view returns (uint256) {
        return accountTokens[owner];
    }

    /**
     * @notice Get the underlying balance of the `owner`
     * @dev This also accrues interest in a transaction
     * @param owner The address of the account to query
     * @return The amount of underlying owned by `owner`
     */
    function balanceOfUnderlying(address owner) external returns (uint) {
        Exp memory exchangeRate = Exp({mantissa: exchangeRateCurrent()});
        (MathError mErr, uint balance) = mulScalarTruncate(exchangeRate, accountTokens[owner]);
        require(mErr == MathError.NO_ERROR, "balance could not be calculated");
        return balance;
    }

    /**
     * @notice Get a snapshot of the account's balances, and the cached exchange rate
     * @dev This is used by comptroller to more efficiently perform liquidity checks.
     * @param account Address of the account to snapshot
     * @return (possible error, token balance, borrow balance, exchange rate mantissa)
     */
    function getAccountSnapshot(address account) external view returns (uint, uint, uint, uint) {
        uint aTokenBalance = accountTokens[account];
        uint borrowBalance;
        uint exchangeRateMantissa;

        MathError mErr;

        (mErr, borrowBalance) = borrowBalanceStoredInternal(account);
        if (mErr != MathError.NO_ERROR) {
            return (uint(Error.MATH_ERROR), 0, 0, 0);
        }

        (mErr, exchangeRateMantissa) = exchangeRateStoredInternal();
        if (mErr != MathError.NO_ERROR) {
            return (uint(Error.MATH_ERROR), 0, 0, 0);
        }

        return (uint(Error.NO_ERROR), aTokenBalance, borrowBalance, exchangeRateMantissa);
    }

    /**
     * @dev Function to simply retrieve block number
     *  This exists mainly for inheriting test contracts to stub this result.
     */
    function getBlockNumber() internal view returns (uint) {
        return block.number;
    }

    /**
     * @notice Returns the current per-block borrow interest rate for this aToken
     * @return The borrow interest rate per block, scaled by 1e18
     */
    function borrowRatePerBlock() external view returns (uint) {
        return interestRateModel.getBorrowRate(getCashPrior(), totalBorrows, totalReserves);
    }

    /**
     * @notice Returns the current per-block supply interest rate for this aToken
     * @return The supply interest rate per block, scaled by 1e18
     */
    function supplyRatePerBlock() external view returns (uint) {
        return interestRateModel.getSupplyRate(getCashPrior(), totalBorrows, totalReserves, reserveFactorMantissa);
    }

    /**
     * @notice Returns the current total borrows plus accrued interest
     * @return The total borrows with interest
     */
    function totalBorrowsCurrent() external nonReentrant returns (uint) {
        require(accrueInterest() == uint(Error.NO_ERROR), "accrue interest failed");
        return totalBorrows;
    }

    /**
     * @notice Accrue interest to updated borrowIndex and then calculate account's borrow balance using the updated borrowIndex
     * @param account The address whose balance should be calculated after updating borrowIndex
     * @return The calculated balance
     */
    function borrowBalanceCurrent(address account) external nonReentrant returns (uint) {
        require(accrueInterest() == uint(Error.NO_ERROR), "accrue interest failed");
        return borrowBalanceStored(account);
    }

    /**
     * @notice Return the borrow balance of account based on stored data
     * @param account The address whose balance should be calculated
     * @return The calculated balance
     */
    function borrowBalanceStored(address account) public view returns (uint) {
        (MathError err, uint result) = borrowBalanceStoredInternal(account);
        require(err == MathError.NO_ERROR, "borrowBalanceStored: borrowBalanceStoredInternal failed");
        return result;
    }

    /**
     * @notice Return the borrow balance of account based on stored data
     * @param account The address whose balance should be calculated
     * @return (error code, the calculated balance or 0 if error code is non-zero)
     */
    function borrowBalanceStoredInternal(address account) internal view returns (MathError, uint) {
        /* Note: we do not assert that the market is up to date */
        MathError mathErr;
        uint principalTimesIndex;
        uint result;

        /* Get borrowBalance and borrowIndex */
        BorrowSnapshot storage borrowSnapshot = accountBorrows[account];

        /* If borrowBalance = 0 then borrowIndex is likely also 0.
         * Rather than failing the calculation with a division by 0, we immediately return 0 in this case.
         */
        if (borrowSnapshot.principal == 0) {
            return (MathError.NO_ERROR, 0);
        }

        /* Calculate new borrow balance using the interest index:
         *  recentBorrowBalance = borrower.borrowBalance * market.borrowIndex / borrower.borrowIndex
         */
        (mathErr, principalTimesIndex) = mulUInt(borrowSnapshot.principal, borrowIndex);
        if (mathErr != MathError.NO_ERROR) {
            return (mathErr, 0);
        }

        (mathErr, result) = divUInt(principalTimesIndex, borrowSnapshot.interestIndex);
        if (mathErr != MathError.NO_ERROR) {
            return (mathErr, 0);
        }

        return (MathError.NO_ERROR, result);
    }

    /**
     * @notice Accrue interest then return the up-to-date exchange rate
     * @return Calculated exchange rate scaled by 1e18
     */
    function exchangeRateCurrent() public nonReentrant returns (uint) {
        require(accrueInterest() == uint(Error.NO_ERROR), "accrue interest failed");
        return exchangeRateStored();
    }

    /**
     * @notice Calculates the exchange rate from the underlying to the AToken
     * @dev This function does not accrue interest before calculating the exchange rate
     * @return Calculated exchange rate scaled by 1e18
     */
    function exchangeRateStored() public view returns (uint) {
        (MathError err, uint result) = exchangeRateStoredInternal();
        require(err == MathError.NO_ERROR, "exchangeRateStored: exchangeRateStoredInternal failed");
        return result;
    }

    /**
     * @notice Calculates the exchange rate from the underlying to the AToken
     * @dev This function does not accrue interest before calculating the exchange rate
     * @return (error code, calculated exchange rate scaled by 1e18)
     */
    function exchangeRateStoredInternal() internal view returns (MathError, uint) {
        uint _totalSupply = totalSupply;
        if (_totalSupply == 0) {
            /*
             * If there are no tokens minted:
             *  exchangeRate = initialExchangeRate
             */
            return (MathError.NO_ERROR, initialExchangeRateMantissa);
        } else {
            /*
             * Otherwise:
             *  exchangeRate = (totalCash + totalBorrows - totalReserves) / totalSupply
             */
            uint totalCash = getCashPrior();
            uint cashPlusBorrowsMinusReserves;
            Exp memory exchangeRate;
            MathError mathErr;

            (mathErr, cashPlusBorrowsMinusReserves) = addThenSubUInt(totalCash, totalBorrows, totalReserves);
            if (mathErr != MathError.NO_ERROR) {
                return (mathErr, 0);
            }

            (mathErr, exchangeRate) = getExp(cashPlusBorrowsMinusReserves, _totalSupply);
            if (mathErr != MathError.NO_ERROR) {
                return (mathErr, 0);
            }

            return (MathError.NO_ERROR, exchangeRate.mantissa);
        }
    }

    /**
     * @notice Get cash balance of this aToken in the underlying asset
     * @return The quantity of underlying asset owned by this contract
     */
    function getCash() external view returns (uint) {
        return getCashPrior();
    }

    /**
     * @notice Applies accrued interest to total borrows and reserves
     * @dev This calculates interest accrued from the last checkpointed block
     *   up to the current block and writes new checkpoint to storage.
     */
    function accrueInterest() public returns (uint) {
        /* Remember the initial block number */
        uint currentBlockNumber = getBlockNumber();
        uint accrualBlockNumberPrior = accrualBlockNumber;

        /* Short-circuit accumulating 0 interest */
        if (accrualBlockNumberPrior == currentBlockNumber) {
            return uint(Error.NO_ERROR);
        }

        /* Read the previous values out of storage */
        uint cashPrior = getCashPrior();
        uint borrowsPrior = totalBorrows;
        uint reservesPrior = totalReserves;
        uint borrowIndexPrior = borrowIndex;

        /* Calculate the current borrow interest rate */
        uint borrowRateMantissa = interestRateModel.getBorrowRate(cashPrior, borrowsPrior, reservesPrior);
        require(borrowRateMantissa <= borrowRateMaxMantissa, "borrow rate is absurdly high");

        /* Calculate the number of blocks elapsed since the last accrual */
        (MathError mathErr, uint blockDelta) = subUInt(currentBlockNumber, accrualBlockNumberPrior);
        require(mathErr == MathError.NO_ERROR, "could not calculate block delta");

        /*
         * Calculate the interest accumulated into borrows and reserves and the new index:
         *  simpleInterestFactor = borrowRate * blockDelta
         *  interestAccumulated = simpleInterestFactor * totalBorrows
         *  totalBorrowsNew = interestAccumulated + totalBorrows
         *  totalReservesNew = interestAccumulated * reserveFactor + totalReserves
         *  borrowIndexNew = simpleInterestFactor * borrowIndex + borrowIndex
         */

        Exp memory simpleInterestFactor;
        uint interestAccumulated;
        uint totalBorrowsNew;
        uint totalReservesNew;
        uint borrowIndexNew;

        (mathErr, simpleInterestFactor) = mulScalar(Exp({mantissa: borrowRateMantissa}), blockDelta);
        if (mathErr != MathError.NO_ERROR) {
            return failOpaque(Error.MATH_ERROR, FailureInfo.ACCRUE_INTEREST_SIMPLE_INTEREST_FACTOR_CALCULATION_FAILED, uint(mathErr));
        }

        (mathErr, interestAccumulated) = mulScalarTruncate(simpleInterestFactor, borrowsPrior);
        if (mathErr != MathError.NO_ERROR) {
            return failOpaque(Error.MATH_ERROR, FailureInfo.ACCRUE_INTEREST_ACCUMULATED_INTEREST_CALCULATION_FAILED, uint(mathErr));
        }

        (mathErr, totalBorrowsNew) = addUInt(interestAccumulated, borrowsPrior);
        if (mathErr != MathError.NO_ERROR) {
            return failOpaque(Error.MATH_ERROR, FailureInfo.ACCRUE_INTEREST_NEW_TOTAL_BORROWS_CALCULATION_FAILED, uint(mathErr));
        }

        (mathErr, totalReservesNew) = mulScalarTruncateAddUInt(Exp({mantissa: reserveFactorMantissa}), interestAccumulated, reservesPrior);
        if (mathErr != MathError.NO_ERROR) {
            return failOpaque(Error.MATH_ERROR, FailureInfo.ACCRUE_INTEREST_NEW_TOTAL_RESERVES_CALCULATION_FAILED, uint(mathErr));
        }

        (mathErr, borrowIndexNew) = mulScalarTruncateAddUInt(simpleInterestFactor, borrowIndexPrior, borrowIndexPrior);
        if (mathErr != MathError.NO_ERROR) {
            return failOpaque(Error.MATH_ERROR, FailureInfo.ACCRUE_INTEREST_NEW_BORROW_INDEX_CALCULATION_FAILED, uint(mathErr));
        }

        /////////////////////////
        // EFFECTS & INTERACTIONS
        // (No safe failures beyond this point)

        /* We write the previously calculated values into storage */
        accrualBlockNumber = currentBlockNumber;
        borrowIndex = borrowIndexNew;
        totalBorrows = totalBorrowsNew;
        totalReserves = totalReservesNew;

        /* We emit an AccrueInterest event */
        emit AccrueInterest(cashPrior, interestAccumulated, borrowIndexNew, totalBorrowsNew);

        return uint(Error.NO_ERROR);
    }

    /**
     * @notice Sender supplies assets into the market and receives aTokens in exchange
     * @dev Accrues interest whether or not the operation succeeds, unless reverted
     * @param mintAmount The amount of the underlying asset to supply
     * @return (uint, uint) An error code (0=success, otherwise a failure, see ErrorReporter.sol), and the actual mint amount.
     */
    function mintInternal(uint mintAmount) internal nonReentrant returns (uint, uint) {
        uint error = accrueInterest();
        if (error != uint(Error.NO_ERROR)) {
            // accrueInterest emits logs on errors, but we still want to log the fact that an attempted borrow failed
            return (fail(Error(error), FailureInfo.MINT_ACCRUE_INTEREST_FAILED), 0);
        }
        // mintFresh emits the actual Mint event if successful and logs on errors, so we don't need to
        return mintFresh(msg.sender, mintAmount);
    }

    struct MintLocalVars {
        Error err;
        MathError mathErr;
        uint exchangeRateMantissa;
        uint mintTokens;
        uint totalSupplyNew;
        uint accountTokensNew;
        uint actualMintAmount;
    }

    /**
     * @notice User supplies assets into the market and receives aTokens in exchange
     * @dev Assumes interest has already been accrued up to the current block
     * @param minter The address of the account which is supplying the assets
     * @param mintAmount The amount of the underlying asset to supply
     * @return (uint, uint) An error code (0=success, otherwise a failure, see ErrorReporter.sol), and the actual mint amount.
     */
    function mintFresh(address minter, uint mintAmount) internal returns (uint, uint) {
        /* Fail if mint not allowed */
        uint allowed = comptroller.mintAllowed(address(this), minter, mintAmount);
        if (allowed != 0) {
            return (failOpaque(Error.COMPTROLLER_REJECTION, FailureInfo.MINT_COMPTROLLER_REJECTION, allowed), 0);
        }

        /* Verify market's block number equals current block number */
        if (accrualBlockNumber != getBlockNumber()) {
            return (fail(Error.MARKET_NOT_FRESH, FailureInfo.MINT_FRESHNESS_CHECK), 0);
        }

        MintLocalVars memory vars;

        (vars.mathErr, vars.exchangeRateMantissa) = exchangeRateStoredInternal();
        if (vars.mathErr != MathError.NO_ERROR) {
            return (failOpaque(Error.MATH_ERROR, FailureInfo.MINT_EXCHANGE_RATE_READ_FAILED, uint(vars.mathErr)), 0);
        }

        /////////////////////////
        // EFFECTS & INTERACTIONS
        // (No safe failures beyond this point)

        /*
         *  We call `doTransferIn` for the minter and the mintAmount.
         *  Note: The aToken must handle variations between ERC-20 and ETH underlying.
         *  `doTransferIn` reverts if anything goes wrong, since we can't be sure if
         *  side-effects occurred. The function returns the amount actually transferred,
         *  in case of a fee. On success, the aToken holds an additional `actualMintAmount`
         *  of cash.
         */
        vars.actualMintAmount = doTransferIn(minter, mintAmount);

        /*
         * We get the current exchange rate and calculate the number of aTokens to be minted:
         *  mintTokens = actualMintAmount / exchangeRate
         */

        (vars.mathErr, vars.mintTokens) = divScalarByExpTruncate(vars.actualMintAmount, Exp({mantissa: vars.exchangeRateMantissa}));
        require(vars.mathErr == MathError.NO_ERROR, "MINT_EXCHANGE_CALCULATION_FAILED");

        /*
         * We calculate the new total supply of aTokens and minter token balance, checking for overflow:
         *  totalSupplyNew = totalSupply + mintTokens
         *  accountTokensNew = accountTokens[minter] + mintTokens
         */
        (vars.mathErr, vars.totalSupplyNew) = addUInt(totalSupply, vars.mintTokens);
        require(vars.mathErr == MathError.NO_ERROR, "MINT_NEW_TOTAL_SUPPLY_CALCULATION_FAILED");

        (vars.mathErr, vars.accountTokensNew) = addUInt(accountTokens[minter], vars.mintTokens);
        require(vars.mathErr == MathError.NO_ERROR, "MINT_NEW_ACCOUNT_BALANCE_CALCULATION_FAILED");

        /* We write previously calculated values into storage */
        totalSupply = vars.totalSupplyNew;
        accountTokens[minter] = vars.accountTokensNew;

        /* We emit a Mint event, and a Transfer event */
        emit Mint(minter, vars.actualMintAmount, vars.mintTokens);
        emit Transfer(address(this), minter, vars.mintTokens);

        /* We call the defense hook */
        // unused function
        // comptroller.mintVerify(address(this), minter, vars.actualMintAmount, vars.mintTokens);

        return (uint(Error.NO_ERROR), vars.actualMintAmount);
    }

    /**
     * @notice Sender redeems aTokens in exchange for the underlying asset
     * @dev Accrues interest whether or not the operation succeeds, unless reverted
     * @param redeemTokens The number of aTokens to redeem into underlying
     * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
     */
    function redeemInternal(uint redeemTokens) internal nonReentrant returns (uint) {
        uint error = accrueInterest();
        if (error != uint(Error.NO_ERROR)) {
            // accrueInterest emits logs on errors, but we still want to log the fact that an attempted redeem failed
            return fail(Error(error), FailureInfo.REDEEM_ACCRUE_INTEREST_FAILED);
        }
        // redeemFresh emits redeem-specific logs on errors, so we don't need to
        return redeemFresh(msg.sender, redeemTokens, 0);
    }

    /**
     * @notice Sender redeems aTokens in exchange for a specified amount of underlying asset
     * @dev Accrues interest whether or not the operation succeeds, unless reverted
     * @param redeemAmount The amount of underlying to receive from redeeming aTokens
     * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
     */
    function redeemUnderlyingInternal(uint redeemAmount) internal nonReentrant returns (uint) {
        uint error = accrueInterest();
        if (error != uint(Error.NO_ERROR)) {
            // accrueInterest emits logs on errors, but we still want to log the fact that an attempted redeem failed
            return fail(Error(error), FailureInfo.REDEEM_ACCRUE_INTEREST_FAILED);
        }
        // redeemFresh emits redeem-specific logs on errors, so we don't need to
        return redeemFresh(msg.sender, 0, redeemAmount);
    }

    struct RedeemLocalVars {
        Error err;
        MathError mathErr;
        uint exchangeRateMantissa;
        uint redeemTokens;
        uint redeemAmount;
        uint totalSupplyNew;
        uint accountTokensNew;
    }

    /**
     * @notice User redeems aTokens in exchange for the underlying asset
     * @dev Assumes interest has already been accrued up to the current block
     * @param redeemer The address of the account which is redeeming the tokens
     * @param redeemTokensIn The number of aTokens to redeem into underlying (only one of redeemTokensIn or redeemAmountIn may be non-zero)
     * @param redeemAmountIn The number of underlying tokens to receive from redeeming aTokens (only one of redeemTokensIn or redeemAmountIn may be non-zero)
     * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
     */
    function redeemFresh(address payable redeemer, uint redeemTokensIn, uint redeemAmountIn) internal returns (uint) {
        require(redeemTokensIn == 0 || redeemAmountIn == 0, "one of redeemTokensIn or redeemAmountIn must be zero");

        RedeemLocalVars memory vars;

        /* exchangeRate = invoke Exchange Rate Stored() */
        (vars.mathErr, vars.exchangeRateMantissa) = exchangeRateStoredInternal();
        if (vars.mathErr != MathError.NO_ERROR) {
            return failOpaque(Error.MATH_ERROR, FailureInfo.REDEEM_EXCHANGE_RATE_READ_FAILED, uint(vars.mathErr));
        }

        /* If redeemTokensIn > 0: */
        if (redeemTokensIn > 0) {
            /*
             * We calculate the exchange rate and the amount of underlying to be redeemed:
             *  redeemTokens = redeemTokensIn
             *  redeemAmount = redeemTokensIn x exchangeRateCurrent
             */
            vars.redeemTokens = redeemTokensIn;

            (vars.mathErr, vars.redeemAmount) = mulScalarTruncate(Exp({mantissa: vars.exchangeRateMantissa}), redeemTokensIn);
            if (vars.mathErr != MathError.NO_ERROR) {
                return failOpaque(Error.MATH_ERROR, FailureInfo.REDEEM_EXCHANGE_TOKENS_CALCULATION_FAILED, uint(vars.mathErr));
            }
        } else {
            /*
             * We get the current exchange rate and calculate the amount to be redeemed:
             *  redeemTokens = redeemAmountIn / exchangeRate
             *  redeemAmount = redeemAmountIn
             */

            (vars.mathErr, vars.redeemTokens) = divScalarByExpTruncate(redeemAmountIn, Exp({mantissa: vars.exchangeRateMantissa}));
            if (vars.mathErr != MathError.NO_ERROR) {
                return failOpaque(Error.MATH_ERROR, FailureInfo.REDEEM_EXCHANGE_AMOUNT_CALCULATION_FAILED, uint(vars.mathErr));
            }

            vars.redeemAmount = redeemAmountIn;
        }

        /* Fail if redeem not allowed */
        uint allowed = comptroller.redeemAllowed(address(this), redeemer, vars.redeemTokens);
        if (allowed != 0) {
            return failOpaque(Error.COMPTROLLER_REJECTION, FailureInfo.REDEEM_COMPTROLLER_REJECTION, allowed);
        }

        /* Verify market's block number equals current block number */
        if (accrualBlockNumber != getBlockNumber()) {
            return fail(Error.MARKET_NOT_FRESH, FailureInfo.REDEEM_FRESHNESS_CHECK);
        }

        /*
         * We calculate the new total supply and redeemer balance, checking for underflow:
         *  totalSupplyNew = totalSupply - redeemTokens
         *  accountTokensNew = accountTokens[redeemer] - redeemTokens
         */
        (vars.mathErr, vars.totalSupplyNew) = subUInt(totalSupply, vars.redeemTokens);
        if (vars.mathErr != MathError.NO_ERROR) {
            return failOpaque(Error.MATH_ERROR, FailureInfo.REDEEM_NEW_TOTAL_SUPPLY_CALCULATION_FAILED, uint(vars.mathErr));
        }

        (vars.mathErr, vars.accountTokensNew) = subUInt(accountTokens[redeemer], vars.redeemTokens);
        if (vars.mathErr != MathError.NO_ERROR) {
            return failOpaque(Error.MATH_ERROR, FailureInfo.REDEEM_NEW_ACCOUNT_BALANCE_CALCULATION_FAILED, uint(vars.mathErr));
        }

        /* Fail gracefully if protocol has insufficient cash */
        if (getCashPrior() < vars.redeemAmount) {
            return fail(Error.TOKEN_INSUFFICIENT_CASH, FailureInfo.REDEEM_TRANSFER_OUT_NOT_POSSIBLE);
        }

        /////////////////////////
        // EFFECTS & INTERACTIONS
        // (No safe failures beyond this point)

        /*
         * We invoke doTransferOut for the redeemer and the redeemAmount.
         *  Note: The aToken must handle variations between ERC-20 and ETH underlying.
         *  On success, the aToken has redeemAmount less of cash.
         *  doTransferOut reverts if anything goes wrong, since we can't be sure if side effects occurred.
         */
        doTransferOut(redeemer, vars.redeemAmount);

        /* We write previously calculated values into storage */
        totalSupply = vars.totalSupplyNew;
        accountTokens[redeemer] = vars.accountTokensNew;

        /* We emit a Transfer event, and a Redeem event */
        emit Transfer(redeemer, address(this), vars.redeemTokens);
        emit Redeem(redeemer, vars.redeemAmount, vars.redeemTokens);

        /* We call the defense hook */
        comptroller.redeemVerify(address(this), redeemer, vars.redeemAmount, vars.redeemTokens);

        return uint(Error.NO_ERROR);
    }

    /**
      * @notice Sender borrows assets from the protocol to their own address
      * @param borrowAmount The amount of the underlying asset to borrow
      * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
      */
    function borrowInternal(uint borrowAmount) internal nonReentrant returns (uint) {
        uint error = accrueInterest();
        if (error != uint(Error.NO_ERROR)) {
            // accrueInterest emits logs on errors, but we still want to log the fact that an attempted borrow failed
            return fail(Error(error), FailureInfo.BORROW_ACCRUE_INTEREST_FAILED);
        }
        // borrowFresh emits borrow-specific logs on errors, so we don't need to
        return borrowFresh(msg.sender, borrowAmount);
    }

    struct BorrowLocalVars {
        MathError mathErr;
        uint accountBorrows;
        uint accountBorrowsNew;
        uint totalBorrowsNew;
    }

    /**
      * @notice Users borrow assets from the protocol to their own address
      * @param borrowAmount The amount of the underlying asset to borrow
      * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
      */
    function borrowFresh(address payable borrower, uint borrowAmount) internal returns (uint) {
        /* Fail if borrow not allowed */
        uint allowed = comptroller.borrowAllowed(address(this), borrower, borrowAmount);
        if (allowed != 0) {
            return failOpaque(Error.COMPTROLLER_REJECTION, FailureInfo.BORROW_COMPTROLLER_REJECTION, allowed);
        }

        /* Verify market's block number equals current block number */
        if (accrualBlockNumber != getBlockNumber()) {
            return fail(Error.MARKET_NOT_FRESH, FailureInfo.BORROW_FRESHNESS_CHECK);
        }

        /* Fail gracefully if protocol has insufficient underlying cash */
        if (getCashPrior() < borrowAmount) {
            return fail(Error.TOKEN_INSUFFICIENT_CASH, FailureInfo.BORROW_CASH_NOT_AVAILABLE);
        }

        BorrowLocalVars memory vars;

        /*
         * We calculate the new borrower and total borrow balances, failing on overflow:
         *  accountBorrowsNew = accountBorrows + borrowAmount
         *  totalBorrowsNew = totalBorrows + borrowAmount
         */
        (vars.mathErr, vars.accountBorrows) = borrowBalanceStoredInternal(borrower);
        if (vars.mathErr != MathError.NO_ERROR) {
            return failOpaque(Error.MATH_ERROR, FailureInfo.BORROW_ACCUMULATED_BALANCE_CALCULATION_FAILED, uint(vars.mathErr));
        }

        (vars.mathErr, vars.accountBorrowsNew) = addUInt(vars.accountBorrows, borrowAmount);
        if (vars.mathErr != MathError.NO_ERROR) {
            return failOpaque(Error.MATH_ERROR, FailureInfo.BORROW_NEW_ACCOUNT_BORROW_BALANCE_CALCULATION_FAILED, uint(vars.mathErr));
        }

        (vars.mathErr, vars.totalBorrowsNew) = addUInt(totalBorrows, borrowAmount);
        if (vars.mathErr != MathError.NO_ERROR) {
            return failOpaque(Error.MATH_ERROR, FailureInfo.BORROW_NEW_TOTAL_BALANCE_CALCULATION_FAILED, uint(vars.mathErr));
        }

        /////////////////////////
        // EFFECTS & INTERACTIONS
        // (No safe failures beyond this point)

        /*
         * We invoke doTransferOut for the borrower and the borrowAmount.
         *  Note: The aToken must handle variations between ERC-20 and ETH underlying.
         *  On success, the aToken borrowAmount less of cash.
         *  doTransferOut reverts if anything goes wrong, since we can't be sure if side effects occurred.
         */
        doTransferOut(borrower, borrowAmount);

        /* We write the previously calculated values into storage */
        accountBorrows[borrower].principal = vars.accountBorrowsNew;
        accountBorrows[borrower].interestIndex = borrowIndex;
        totalBorrows = vars.totalBorrowsNew;

        /* We emit a Borrow event */
        emit Borrow(borrower, borrowAmount, vars.accountBorrowsNew, vars.totalBorrowsNew);

        /* We call the defense hook */
        // unused function
        // comptroller.borrowVerify(address(this), borrower, borrowAmount);

        return uint(Error.NO_ERROR);
    }

    /**
     * @notice Sender repays their own borrow
     * @param repayAmount The amount to repay
     * @return (uint, uint) An error code (0=success, otherwise a failure, see ErrorReporter.sol), and the actual repayment amount.
     */
    function repayBorrowInternal(uint repayAmount) internal nonReentrant returns (uint, uint) {
        uint error = accrueInterest();
        if (error != uint(Error.NO_ERROR)) {
            // accrueInterest emits logs on errors, but we still want to log the fact that an attempted borrow failed
            return (fail(Error(error), FailureInfo.REPAY_BORROW_ACCRUE_INTEREST_FAILED), 0);
        }
        // repayBorrowFresh emits repay-borrow-specific logs on errors, so we don't need to
        return repayBorrowFresh(msg.sender, msg.sender, repayAmount);
    }

    /**
     * @notice Sender repays a borrow belonging to borrower
     * @param borrower the account with the debt being payed off
     * @param repayAmount The amount to repay
     * @return (uint, uint) An error code (0=success, otherwise a failure, see ErrorReporter.sol), and the actual repayment amount.
     */
    function repayBorrowBehalfInternal(address borrower, uint repayAmount) internal nonReentrant returns (uint, uint) {
        uint error = accrueInterest();
        if (error != uint(Error.NO_ERROR)) {
            // accrueInterest emits logs on errors, but we still want to log the fact that an attempted borrow failed
            return (fail(Error(error), FailureInfo.REPAY_BEHALF_ACCRUE_INTEREST_FAILED), 0);
        }
        // repayBorrowFresh emits repay-borrow-specific logs on errors, so we don't need to
        return repayBorrowFresh(msg.sender, borrower, repayAmount);
    }

    struct RepayBorrowLocalVars {
        Error err;
        MathError mathErr;
        uint repayAmount;
        uint borrowerIndex;
        uint accountBorrows;
        uint accountBorrowsNew;
        uint totalBorrowsNew;
        uint actualRepayAmount;
    }

    /**
     * @notice Borrows are repaid by another user (possibly the borrower).
     * @param payer the account paying off the borrow
     * @param borrower the account with the debt being payed off
     * @param repayAmount the amount of undelrying tokens being returned
     * @return (uint, uint) An error code (0=success, otherwise a failure, see ErrorReporter.sol), and the actual repayment amount.
     */
    function repayBorrowFresh(address payer, address borrower, uint repayAmount) internal returns (uint, uint) {
        /* Fail if repayBorrow not allowed */
        uint allowed = comptroller.repayBorrowAllowed(address(this), payer, borrower, repayAmount);
        if (allowed != 0) {
            return (failOpaque(Error.COMPTROLLER_REJECTION, FailureInfo.REPAY_BORROW_COMPTROLLER_REJECTION, allowed), 0);
        }

        /* Verify market's block number equals current block number */
        if (accrualBlockNumber != getBlockNumber()) {
            return (fail(Error.MARKET_NOT_FRESH, FailureInfo.REPAY_BORROW_FRESHNESS_CHECK), 0);
        }

        RepayBorrowLocalVars memory vars;

        /* We remember the original borrowerIndex for verification purposes */
        vars.borrowerIndex = accountBorrows[borrower].interestIndex;

        /* We fetch the amount the borrower owes, with accumulated interest */
        (vars.mathErr, vars.accountBorrows) = borrowBalanceStoredInternal(borrower);
        if (vars.mathErr != MathError.NO_ERROR) {
            return (failOpaque(Error.MATH_ERROR, FailureInfo.REPAY_BORROW_ACCUMULATED_BALANCE_CALCULATION_FAILED, uint(vars.mathErr)), 0);
        }

        /* If repayAmount == -1, repayAmount = accountBorrows */
        if (repayAmount == uint(-1)) {
            vars.repayAmount = vars.accountBorrows;
        } else {
            vars.repayAmount = repayAmount;
        }

        /////////////////////////
        // EFFECTS & INTERACTIONS
        // (No safe failures beyond this point)

        /*
         * We call doTransferIn for the payer and the repayAmount
         *  Note: The aToken must handle variations between ERC-20 and ETH underlying.
         *  On success, the aToken holds an additional repayAmount of cash.
         *  doTransferIn reverts if anything goes wrong, since we can't be sure if side effects occurred.
         *   it returns the amount actually transferred, in case of a fee.
         */
        vars.actualRepayAmount = doTransferIn(payer, vars.repayAmount);

        /*
         * We calculate the new borrower and total borrow balances, failing on underflow:
         *  accountBorrowsNew = accountBorrows - actualRepayAmount
         *  totalBorrowsNew = totalBorrows - actualRepayAmount
         */
        (vars.mathErr, vars.accountBorrowsNew) = subUInt(vars.accountBorrows, vars.actualRepayAmount);
        require(vars.mathErr == MathError.NO_ERROR, "REPAY_BORROW_NEW_ACCOUNT_BORROW_BALANCE_CALCULATION_FAILED");

        (vars.mathErr, vars.totalBorrowsNew) = subUInt(totalBorrows, vars.actualRepayAmount);
        require(vars.mathErr == MathError.NO_ERROR, "REPAY_BORROW_NEW_TOTAL_BALANCE_CALCULATION_FAILED");

        /* We write the previously calculated values into storage */
        accountBorrows[borrower].principal = vars.accountBorrowsNew;
        accountBorrows[borrower].interestIndex = borrowIndex;
        totalBorrows = vars.totalBorrowsNew;

        /* We emit a RepayBorrow event */
        emit RepayBorrow(payer, borrower, vars.actualRepayAmount, vars.accountBorrowsNew, vars.totalBorrowsNew);

        /* We call the defense hook */
        // unused function
        // comptroller.repayBorrowVerify(address(this), payer, borrower, vars.actualRepayAmount, vars.borrowerIndex);

        return (uint(Error.NO_ERROR), vars.actualRepayAmount);
    }

    /**
     * @notice The sender liquidates the borrowers collateral.
     *  The collateral seized is transferred to the liquidator.
     * @param borrower The borrower of this aToken to be liquidated
     * @param aTokenCollateral The market in which to seize collateral from the borrower
     * @param repayAmount The amount of the underlying borrowed asset to repay
     * @return (uint, uint) An error code (0=success, otherwise a failure, see ErrorReporter.sol), and the actual repayment amount.
     */
    function liquidateBorrowInternal(address borrower, uint repayAmount, ATokenInterface aTokenCollateral) internal nonReentrant returns (uint, uint) {
        uint error = accrueInterest();
        if (error != uint(Error.NO_ERROR)) {
            // accrueInterest emits logs on errors, but we still want to log the fact that an attempted liquidation failed
            return (fail(Error(error), FailureInfo.LIQUIDATE_ACCRUE_BORROW_INTEREST_FAILED), 0);
        }

        error = aTokenCollateral.accrueInterest();
        if (error != uint(Error.NO_ERROR)) {
            // accrueInterest emits logs on errors, but we still want to log the fact that an attempted liquidation failed
            return (fail(Error(error), FailureInfo.LIQUIDATE_ACCRUE_COLLATERAL_INTEREST_FAILED), 0);
        }

        // liquidateBorrowFresh emits borrow-specific logs on errors, so we don't need to
        return liquidateBorrowFresh(msg.sender, borrower, repayAmount, aTokenCollateral);
    }

    /**
     * @notice The liquidator liquidates the borrowers collateral.
     *  The collateral seized is transferred to the liquidator.
     * @param borrower The borrower of this aToken to be liquidated
     * @param liquidator The address repaying the borrow and seizing collateral
     * @param aTokenCollateral The market in which to seize collateral from the borrower
     * @param repayAmount The amount of the underlying borrowed asset to repay
     * @return (uint, uint) An error code (0=success, otherwise a failure, see ErrorReporter.sol), and the actual repayment amount.
     */
    function liquidateBorrowFresh(address liquidator, address borrower, uint repayAmount, ATokenInterface aTokenCollateral) internal returns (uint, uint) {
        /* Fail if liquidate not allowed */
        uint allowed = comptroller.liquidateBorrowAllowed(address(this), address(aTokenCollateral), liquidator, borrower, repayAmount);
        if (allowed != 0) {
            return (failOpaque(Error.COMPTROLLER_REJECTION, FailureInfo.LIQUIDATE_COMPTROLLER_REJECTION, allowed), 0);
        }

        /* Verify market's block number equals current block number */
        if (accrualBlockNumber != getBlockNumber()) {
            return (fail(Error.MARKET_NOT_FRESH, FailureInfo.LIQUIDATE_FRESHNESS_CHECK), 0);
        }

        /* Verify aTokenCollateral market's block number equals current block number */
        if (aTokenCollateral.accrualBlockNumber() != getBlockNumber()) {
            return (fail(Error.MARKET_NOT_FRESH, FailureInfo.LIQUIDATE_COLLATERAL_FRESHNESS_CHECK), 0);
        }

        /* Fail if borrower = liquidator */
        if (borrower == liquidator) {
            return (fail(Error.INVALID_ACCOUNT_PAIR, FailureInfo.LIQUIDATE_LIQUIDATOR_IS_BORROWER), 0);
        }

        /* Fail if repayAmount = 0 */
        if (repayAmount == 0) {
            return (fail(Error.INVALID_CLOSE_AMOUNT_REQUESTED, FailureInfo.LIQUIDATE_CLOSE_AMOUNT_IS_ZERO), 0);
        }

        /* Fail if repayAmount = -1 */
        if (repayAmount == uint(-1)) {
            return (fail(Error.INVALID_CLOSE_AMOUNT_REQUESTED, FailureInfo.LIQUIDATE_CLOSE_AMOUNT_IS_UINT_MAX), 0);
        }


        /* Fail if repayBorrow fails */
        (uint repayBorrowError, uint actualRepayAmount) = repayBorrowFresh(liquidator, borrower, repayAmount);
        if (repayBorrowError != uint(Error.NO_ERROR)) {
            return (fail(Error(repayBorrowError), FailureInfo.LIQUIDATE_REPAY_BORROW_FRESH_FAILED), 0);
        }

        /////////////////////////
        // EFFECTS & INTERACTIONS
        // (No safe failures beyond this point)

        /* We calculate the number of collateral tokens that will be seized */
        (uint amountSeizeError, uint seizeTokens) = comptroller.liquidateCalculateSeizeTokens(address(this), address(aTokenCollateral), actualRepayAmount);
        require(amountSeizeError == uint(Error.NO_ERROR), "LIQUIDATE_COMPTROLLER_CALCULATE_AMOUNT_SEIZE_FAILED");

        /* Revert if borrower collateral token balance < seizeTokens */
        require(aTokenCollateral.balanceOf(borrower) >= seizeTokens, "LIQUIDATE_SEIZE_TOO_MUCH");

        // If this is also the collateral, run seizeInternal to avoid re-entrancy, otherwise make an external call
        uint seizeError;
        if (address(aTokenCollateral) == address(this)) {
            seizeError = seizeInternal(address(this), liquidator, borrower, seizeTokens);
        } else {
            seizeError = aTokenCollateral.seize(liquidator, borrower, seizeTokens);
        }

        /* Revert if seize tokens fails (since we cannot be sure of side effects) */
        require(seizeError == uint(Error.NO_ERROR), "token seizure failed");

        /* We emit a LiquidateBorrow event */
        emit LiquidateBorrow(liquidator, borrower, actualRepayAmount, address(aTokenCollateral), seizeTokens);

        /* We call the defense hook */
        // unused function
        // comptroller.liquidateBorrowVerify(address(this), address(aTokenCollateral), liquidator, borrower, actualRepayAmount, seizeTokens);

        return (uint(Error.NO_ERROR), actualRepayAmount);
    }

    /**
     * @notice Transfers collateral tokens (this market) to the liquidator.
     * @dev Will fail unless called by another aToken during the process of liquidation.
     *  Its absolutely critical to use msg.sender as the borrowed aToken and not a parameter.
     * @param liquidator The account receiving seized collateral
     * @param borrower The account having collateral seized
     * @param seizeTokens The number of aTokens to seize
     * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
     */
    function seize(address liquidator, address borrower, uint seizeTokens) external nonReentrant returns (uint) {
        return seizeInternal(msg.sender, liquidator, borrower, seizeTokens);
    }

    struct SeizeInternalLocalVars {
        MathError mathErr;
        uint borrowerTokensNew;
        uint liquidatorTokensNew;
        uint liquidatorSeizeTokens;
        uint protocolSeizeTokens;
        uint protocolSeizeAmount;
        uint exchangeRateMantissa;
        uint totalReservesNew;
        uint totalSupplyNew;
    }

    /**
     * @notice Transfers collateral tokens (this market) to the liquidator.
     * @dev Called only during an in-kind liquidation, or by liquidateBorrow during the liquidation of another AToken.
     *  Its absolutely critical to use msg.sender as the seizer aToken and not a parameter.
     * @param seizerToken The contract seizing the collateral (i.e. borrowed aToken)
     * @param liquidator The account receiving seized collateral
     * @param borrower The account having collateral seized
     * @param seizeTokens The number of aTokens to seize
     * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
     */
    function seizeInternal(address seizerToken, address liquidator, address borrower, uint seizeTokens) internal returns (uint) {
        /* Fail if seize not allowed */
        uint allowed = comptroller.seizeAllowed(address(this), seizerToken, liquidator, borrower, seizeTokens);
        if (allowed != 0) {
            return failOpaque(Error.COMPTROLLER_REJECTION, FailureInfo.LIQUIDATE_SEIZE_COMPTROLLER_REJECTION, allowed);
        }

        /* Fail if borrower = liquidator */
        if (borrower == liquidator) {
            return fail(Error.INVALID_ACCOUNT_PAIR, FailureInfo.LIQUIDATE_SEIZE_LIQUIDATOR_IS_BORROWER);
        }

        SeizeInternalLocalVars memory vars;

        /*
         * We calculate the new borrower and liquidator token balances, failing on underflow/overflow:
         *  borrowerTokensNew = accountTokens[borrower] - seizeTokens
         *  liquidatorTokensNew = accountTokens[liquidator] + seizeTokens
         */
        (vars.mathErr, vars.borrowerTokensNew) = subUInt(accountTokens[borrower], seizeTokens);
        if (vars.mathErr != MathError.NO_ERROR) {
            return failOpaque(Error.MATH_ERROR, FailureInfo.LIQUIDATE_SEIZE_BALANCE_DECREMENT_FAILED, uint(vars.mathErr));
        }

        vars.protocolSeizeTokens = mul_(seizeTokens, Exp({mantissa: protocolSeizeShareMantissa}));
        vars.liquidatorSeizeTokens = sub_(seizeTokens, vars.protocolSeizeTokens);

        (vars.mathErr, vars.exchangeRateMantissa) = exchangeRateStoredInternal();
        require(vars.mathErr == MathError.NO_ERROR, "exchange rate math error");

        vars.protocolSeizeAmount = mul_ScalarTruncate(Exp({mantissa: vars.exchangeRateMantissa}), vars.protocolSeizeTokens);

        vars.totalReservesNew = add_(totalReserves, vars.protocolSeizeAmount);
        vars.totalSupplyNew = sub_(totalSupply, vars.protocolSeizeTokens);

        (vars.mathErr, vars.liquidatorTokensNew) = addUInt(accountTokens[liquidator], vars.liquidatorSeizeTokens);
        if (vars.mathErr != MathError.NO_ERROR) {
            return failOpaque(Error.MATH_ERROR, FailureInfo.LIQUIDATE_SEIZE_BALANCE_INCREMENT_FAILED, uint(vars.mathErr));
        }

        /////////////////////////
        // EFFECTS & INTERACTIONS
        // (No safe failures beyond this point)

        /* We write the previously calculated values into storage */
        totalReserves = vars.totalReservesNew;
        totalSupply = vars.totalSupplyNew;
        accountTokens[borrower] = vars.borrowerTokensNew;
        accountTokens[liquidator] = vars.liquidatorTokensNew;

        /* Emit a Transfer event */
        emit Transfer(borrower, liquidator, vars.liquidatorSeizeTokens);
        emit Transfer(borrower, address(this), vars.protocolSeizeTokens);
        emit ReservesAdded(address(this), vars.protocolSeizeAmount, vars.totalReservesNew);

        /* We call the defense hook */
        // unused function
        // comptroller.seizeVerify(address(this), seizerToken, liquidator, borrower, seizeTokens);

        return uint(Error.NO_ERROR);
    }


    /*** Admin Functions ***/

    /**
      * @notice Begins transfer of admin rights. The newPendingAdmin must call `_acceptAdmin` to finalize the transfer.
      * @dev Admin function to begin change of admin. The newPendingAdmin must call `_acceptAdmin` to finalize the transfer.
      * @param newPendingAdmin New pending admin.
      * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
      */
    function _setPendingAdmin(address payable newPendingAdmin) external returns (uint) {
        // Check caller = admin
        if (msg.sender != admin) {
            return fail(Error.UNAUTHORIZED, FailureInfo.SET_PENDING_ADMIN_OWNER_CHECK);
        }

        // Save current value, if any, for inclusion in log
        address oldPendingAdmin = pendingAdmin;

        // Store pendingAdmin with value newPendingAdmin
        pendingAdmin = newPendingAdmin;

        // Emit NewPendingAdmin(oldPendingAdmin, newPendingAdmin)
        emit NewPendingAdmin(oldPendingAdmin, newPendingAdmin);

        return uint(Error.NO_ERROR);
    }

    /**
      * @notice Accepts transfer of admin rights. msg.sender must be pendingAdmin
      * @dev Admin function for pending admin to accept role and update admin
      * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
      */
    function _acceptAdmin() external returns (uint) {
        // Check caller is pendingAdmin and pendingAdmin ≠ address(0)
        if (msg.sender != pendingAdmin || msg.sender == address(0)) {
            return fail(Error.UNAUTHORIZED, FailureInfo.ACCEPT_ADMIN_PENDING_ADMIN_CHECK);
        }

        // Save current values for inclusion in log
        address oldAdmin = admin;
        address oldPendingAdmin = pendingAdmin;

        // Store admin with value pendingAdmin
        admin = pendingAdmin;

        // Clear the pending value
        pendingAdmin = address(0);

        emit NewAdmin(oldAdmin, admin);
        emit NewPendingAdmin(oldPendingAdmin, pendingAdmin);

        return uint(Error.NO_ERROR);
    }

    /**
      * @notice Sets a new comptroller for the market
      * @dev Admin function to set a new comptroller
      * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
      */
    function _setComptroller(ComptrollerInterface newComptroller) public returns (uint) {
        // Check caller is admin
        if (msg.sender != admin) {
            return fail(Error.UNAUTHORIZED, FailureInfo.SET_COMPTROLLER_OWNER_CHECK);
        }

        ComptrollerInterface oldComptroller = comptroller;
        // Ensure invoke comptroller.isComptroller() returns true
        require(newComptroller.isComptroller(), "marker method returned false");

        // Set market's comptroller to newComptroller
        comptroller = newComptroller;

        // Emit NewComptroller(oldComptroller, newComptroller)
        emit NewComptroller(oldComptroller, newComptroller);

        return uint(Error.NO_ERROR);
    }

    /**
      * @notice accrues interest and sets a new reserve factor for the protocol using _setReserveFactorFresh
      * @dev Admin function to accrue interest and set a new reserve factor
      * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
      */
    function _setReserveFactor(uint newReserveFactorMantissa) external nonReentrant returns (uint) {
        uint error = accrueInterest();
        if (error != uint(Error.NO_ERROR)) {
            // accrueInterest emits logs on errors, but on top of that we want to log the fact that an attempted reserve factor change failed.
            return fail(Error(error), FailureInfo.SET_RESERVE_FACTOR_ACCRUE_INTEREST_FAILED);
        }
        // _setReserveFactorFresh emits reserve-factor-specific logs on errors, so we don't need to.
        return _setReserveFactorFresh(newReserveFactorMantissa);
    }

    /**
      * @notice Sets a new reserve factor for the protocol (*requires fresh interest accrual)
      * @dev Admin function to set a new reserve factor
      * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
      */
    function _setReserveFactorFresh(uint newReserveFactorMantissa) internal returns (uint) {
        // Check caller is admin
        if (msg.sender != admin) {
            return fail(Error.UNAUTHORIZED, FailureInfo.SET_RESERVE_FACTOR_ADMIN_CHECK);
        }

        // Verify market's block number equals current block number
        if (accrualBlockNumber != getBlockNumber()) {
            return fail(Error.MARKET_NOT_FRESH, FailureInfo.SET_RESERVE_FACTOR_FRESH_CHECK);
        }

        // Check newReserveFactor ≤ maxReserveFactor
        if (newReserveFactorMantissa > reserveFactorMaxMantissa) {
            return fail(Error.BAD_INPUT, FailureInfo.SET_RESERVE_FACTOR_BOUNDS_CHECK);
        }

        uint oldReserveFactorMantissa = reserveFactorMantissa;
        reserveFactorMantissa = newReserveFactorMantissa;

        emit NewReserveFactor(oldReserveFactorMantissa, newReserveFactorMantissa);

        return uint(Error.NO_ERROR);
    }

    /**
     * @notice Accrues interest and reduces reserves by transferring from msg.sender
     * @param addAmount Amount of addition to reserves
     * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
     */
    function _addReservesInternal(uint addAmount) internal nonReentrant returns (uint) {
        uint error = accrueInterest();
        if (error != uint(Error.NO_ERROR)) {
            // accrueInterest emits logs on errors, but on top of that we want to log the fact that an attempted reduce reserves failed.
            return fail(Error(error), FailureInfo.ADD_RESERVES_ACCRUE_INTEREST_FAILED);
        }

        // _addReservesFresh emits reserve-addition-specific logs on errors, so we don't need to.
        (error, ) = _addReservesFresh(addAmount);
        return error;
    }

    /**
     * @notice Add reserves by transferring from caller
     * @dev Requires fresh interest accrual
     * @param addAmount Amount of addition to reserves
     * @return (uint, uint) An error code (0=success, otherwise a failure (see ErrorReporter.sol for details)) and the actual amount added, net token fees
     */
    function _addReservesFresh(uint addAmount) internal returns (uint, uint) {
        // totalReserves + actualAddAmount
        uint totalReservesNew;
        uint actualAddAmount;

        // We fail gracefully unless market's block number equals current block number
        if (accrualBlockNumber != getBlockNumber()) {
            return (fail(Error.MARKET_NOT_FRESH, FailureInfo.ADD_RESERVES_FRESH_CHECK), actualAddAmount);
        }

        /////////////////////////
        // EFFECTS & INTERACTIONS
        // (No safe failures beyond this point)

        /*
         * We call doTransferIn for the caller and the addAmount
         *  Note: The aToken must handle variations between ERC-20 and ETH underlying.
         *  On success, the aToken holds an additional addAmount of cash.
         *  doTransferIn reverts if anything goes wrong, since we can't be sure if side effects occurred.
         *  it returns the amount actually transferred, in case of a fee.
         */

        actualAddAmount = doTransferIn(msg.sender, addAmount);

        totalReservesNew = totalReserves + actualAddAmount;

        /* Revert on overflow */
        require(totalReservesNew >= totalReserves, "add reserves unexpected overflow");

        // Store reserves[n+1] = reserves[n] + actualAddAmount
        totalReserves = totalReservesNew;

        /* Emit NewReserves(admin, actualAddAmount, reserves[n+1]) */
        emit ReservesAdded(msg.sender, actualAddAmount, totalReservesNew);

        /* Return (NO_ERROR, actualAddAmount) */
        return (uint(Error.NO_ERROR), actualAddAmount);
    }


    /**
     * @notice Accrues interest and reduces reserves by transferring to admin
     * @param reduceAmount Amount of reduction to reserves
     * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
     */
    function _reduceReserves(uint reduceAmount) external nonReentrant returns (uint) {
        uint error = accrueInterest();
        if (error != uint(Error.NO_ERROR)) {
            // accrueInterest emits logs on errors, but on top of that we want to log the fact that an attempted reduce reserves failed.
            return fail(Error(error), FailureInfo.REDUCE_RESERVES_ACCRUE_INTEREST_FAILED);
        }
        // _reduceReservesFresh emits reserve-reduction-specific logs on errors, so we don't need to.
        return _reduceReservesFresh(reduceAmount);
    }

    /**
     * @notice Reduces reserves by transferring to admin
     * @dev Requires fresh interest accrual
     * @param reduceAmount Amount of reduction to reserves
     * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
     */
    function _reduceReservesFresh(uint reduceAmount) internal returns (uint) {
        // totalReserves - reduceAmount
        uint totalReservesNew;

        // Check caller is admin
        if (msg.sender != admin) {
            return fail(Error.UNAUTHORIZED, FailureInfo.REDUCE_RESERVES_ADMIN_CHECK);
        }

        // We fail gracefully unless market's block number equals current block number
        if (accrualBlockNumber != getBlockNumber()) {
            return fail(Error.MARKET_NOT_FRESH, FailureInfo.REDUCE_RESERVES_FRESH_CHECK);
        }

        // Fail gracefully if protocol has insufficient underlying cash
        if (getCashPrior() < reduceAmount) {
            return fail(Error.TOKEN_INSUFFICIENT_CASH, FailureInfo.REDUCE_RESERVES_CASH_NOT_AVAILABLE);
        }

        // Check reduceAmount ≤ reserves[n] (totalReserves)
        if (reduceAmount > totalReserves) {
            return fail(Error.BAD_INPUT, FailureInfo.REDUCE_RESERVES_VALIDATION);
        }

        /////////////////////////
        // EFFECTS & INTERACTIONS
        // (No safe failures beyond this point)

        totalReservesNew = totalReserves - reduceAmount;
        // We checked reduceAmount <= totalReserves above, so this should never revert.
        require(totalReservesNew <= totalReserves, "reduce reserves unexpected underflow");

        // Store reserves[n+1] = reserves[n] - reduceAmount
        totalReserves = totalReservesNew;

        // doTransferOut reverts if anything goes wrong, since we can't be sure if side effects occurred.
        doTransferOut(admin, reduceAmount);

        emit ReservesReduced(admin, reduceAmount, totalReservesNew);

        return uint(Error.NO_ERROR);
    }

    /**
     * @notice accrues interest and updates the interest rate model using _setInterestRateModelFresh
     * @dev Admin function to accrue interest and update the interest rate model
     * @param newInterestRateModel the new interest rate model to use
     * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
     */
    function _setInterestRateModel(InterestRateModel newInterestRateModel) public returns (uint) {
        uint error = accrueInterest();
        if (error != uint(Error.NO_ERROR)) {
            // accrueInterest emits logs on errors, but on top of that we want to log the fact that an attempted change of interest rate model failed
            return fail(Error(error), FailureInfo.SET_INTEREST_RATE_MODEL_ACCRUE_INTEREST_FAILED);
        }
        // _setInterestRateModelFresh emits interest-rate-model-update-specific logs on errors, so we don't need to.
        return _setInterestRateModelFresh(newInterestRateModel);
    }

    /**
     * @notice updates the interest rate model (*requires fresh interest accrual)
     * @dev Admin function to update the interest rate model
     * @param newInterestRateModel the new interest rate model to use
     * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
     */
    function _setInterestRateModelFresh(InterestRateModel newInterestRateModel) internal returns (uint) {

        // Used to store old model for use in the event that is emitted on success
        InterestRateModel oldInterestRateModel;

        // Check caller is admin
        if (msg.sender != admin) {
            return fail(Error.UNAUTHORIZED, FailureInfo.SET_INTEREST_RATE_MODEL_OWNER_CHECK);
        }

        // We fail gracefully unless market's block number equals current block number
        if (accrualBlockNumber != getBlockNumber()) {
            return fail(Error.MARKET_NOT_FRESH, FailureInfo.SET_INTEREST_RATE_MODEL_FRESH_CHECK);
        }

        // Track the market's current interest rate model
        oldInterestRateModel = interestRateModel;

        // Ensure invoke newInterestRateModel.isInterestRateModel() returns true
        require(newInterestRateModel.isInterestRateModel(), "marker method returned false");

        // Set the interest rate model to newInterestRateModel
        interestRateModel = newInterestRateModel;

        // Emit NewMarketInterestRateModel(oldInterestRateModel, newInterestRateModel)
        emit NewMarketInterestRateModel(oldInterestRateModel, newInterestRateModel);

        return uint(Error.NO_ERROR);
    }

    /*** Safe Token ***/

    /**
     * @notice Gets balance of this contract in terms of the underlying
     * @dev This excludes the value of the current message, if any
     * @return The quantity of underlying owned by this contract
     */
    function getCashPrior() internal view returns (uint);

    /**
     * @dev Performs a transfer in, reverting upon failure. Returns the amount actually transferred to the protocol, in case of a fee.
     *  This may revert due to insufficient balance or insufficient allowance.
     */
    function doTransferIn(address from, uint amount) internal returns (uint);

    /**
     * @dev Performs a transfer out, ideally returning an explanatory error code upon failure tather than reverting.
     *  If caller has not called checked protocol's balance, may revert due to insufficient cash held in the contract.
     *  If caller has checked protocol's balance, and verified it is >= amount, this should not revert in normal conditions.
     */
    function doTransferOut(address payable to, uint amount) internal;


    /*** Reentrancy Guard ***/

    /**
     * @dev Prevents a contract from calling itself, directly or indirectly.
     */
    modifier nonReentrant() {
        require(_notEntered, "re-entered");
        _notEntered = false;
        _;
        _notEntered = true; // get a gas-refund post-Istanbul
    }
}

// File: contracts/PriceOracle.sol

pragma solidity ^0.5.16;


contract PriceOracle {
    /// @notice Indicator that this is a PriceOracle contract (for inspection)
    bool public constant isPriceOracle = true;

    /**
      * @notice Get the underlying price of a aToken asset
      * @param aToken The aToken to get the underlying price of
      * @return The underlying asset price mantissa (scaled by 1e18).
      *  Zero means the price is unavailable.
      */
    function getUnderlyingPrice(AToken aToken) external view returns (uint);
}

// File: contracts/ComptrollerStorage.sol

pragma solidity ^0.5.16;



contract UnitrollerAdminStorage {
    /**
    * @notice Administrator for this contract
    */
    address public admin;

    /**
    * @notice Pending administrator for this contract
    */
    address public pendingAdmin;

    /**
    * @notice Active brains of Unitroller
    */
    address public comptrollerImplementation;

    /**
    * @notice Pending brains of Unitroller
    */
    address public pendingComptrollerImplementation;
}

contract ComptrollerV1Storage is UnitrollerAdminStorage {

    /**
     * @notice Oracle which gives the price of any given asset
     */
    PriceOracle public oracle;

    /**
     * @notice Multiplier used to calculate the maximum repayAmount when liquidating a borrow
     */
    uint public closeFactorMantissa;

    /**
     * @notice Multiplier representing the discount on collateral that a liquidator receives
     */
    uint public liquidationIncentiveMantissa;

    /**
     * @notice Max number of assets a single account can participate in (borrow or use as collateral)
     */
    uint public maxAssets;

    /**
     * @notice Per-account mapping of "assets you are in", capped by maxAssets
     */
    mapping(address => AToken[]) public accountAssets;

}

contract ComptrollerV2Storage is ComptrollerV1Storage {
    struct Market {
        /// @notice Whether or not this market is listed
        bool isListed;

        /**
         * @notice Multiplier representing the most one can borrow against their collateral in this market.
         *  For instance, 0.9 to allow borrowing 90% of collateral value.
         *  Must be between 0 and 1, and stored as a mantissa.
         */
        uint collateralFactorMantissa;

        /// @notice Per-market mapping of "accounts in this asset"
        mapping(address => bool) accountMembership;

        /// @notice Whether or not this market receives ARS
        bool isComped;
    }

    /**
     * @notice Official mapping of aTokens -> Market metadata
     * @dev Used e.g. to determine if a market is supported
     */
    mapping(address => Market) public markets;


    /**
     * @notice The Pause Guardian can pause certain actions as a safety mechanism.
     *  Actions which allow users to remove their own assets cannot be paused.
     *  Liquidation / seizing / transfer can only be paused globally, not by market.
     */
    address public pauseGuardian;
    bool public _mintGuardianPaused;
    bool public _borrowGuardianPaused;
    bool public transferGuardianPaused;
    bool public seizeGuardianPaused;
    mapping(address => bool) public mintGuardianPaused;
    mapping(address => bool) public borrowGuardianPaused;
}

contract ComptrollerV3Storage is ComptrollerV2Storage {
    struct ArsMarketState {
        /// @notice The market's last updated arsBorrowIndex or arsSupplyIndex
        uint224 index;

        /// @notice The block number the index was last updated at
        uint32 block;
    }

    /// @notice A list of all markets
    AToken[] public allMarkets;

    /// @notice The rate at which the flywheel distributes ARS, per block
    uint public arsRate;

    /// @notice The portion of arsRate that each market currently receives
    mapping(address => uint) public arsSpeeds;

    /// @notice The ARS market supply state for each market
    mapping(address => ArsMarketState) public arsSupplyState;

    /// @notice The ARS market borrow state for each market
    mapping(address => ArsMarketState) public arsBorrowState;

    /// @notice The ARS borrow index for each market for each supplier as of the last time they accrued ARS
    mapping(address => mapping(address => uint)) public arsSupplierIndex;

    /// @notice The ARS borrow index for each market for each borrower as of the last time they accrued ARS
    mapping(address => mapping(address => uint)) public arsBorrowerIndex;

    /// @notice The ARS accrued but not yet transferred to each user
    mapping(address => uint) public arsAccrued;
}

contract ComptrollerV4Storage is ComptrollerV3Storage {
    // @notice The borrowCapGuardian can set borrowCaps to any number for any market. Lowering the borrow cap could disable borrowing on the given market.
    address public borrowCapGuardian;

    // @notice Borrow caps enforced by borrowAllowed for each aToken address. Defaults to zero which corresponds to unlimited borrowing.
    mapping(address => uint) public borrowCaps;
}

contract ComptrollerV5Storage is ComptrollerV4Storage {
    /// @notice The portion of ARS that each contributor receives per block
    mapping(address => uint) public arsContributorSpeeds;

    /// @notice Last block at which a contributor's ARS rewards have been allocated
    mapping(address => uint) public lastContributorBlock;
}

contract ComptrollerV6Storage is ComptrollerV5Storage {
    /// @notice The rate at which ars is distributed to the corresponding borrow market (per block)
    mapping(address => uint) public arsBorrowSpeeds;

    /// @notice The rate at which ars is distributed to the corresponding supply market (per block)
    mapping(address => uint) public arsSupplySpeeds;
}

contract ComptrollerV7Storage is ComptrollerV6Storage {
    /// @notice Flag indicating whether the function to fix ARS accruals has been executed (RE: proposal 62 bug)
    bool public proposal65FixExecuted;

    /// @notice Accounting storage mapping account addresses to how much ARS they owe the protocol.
    mapping(address => uint) public arsReceivable;
}

// File: contracts/Unitroller.sol

pragma solidity ^0.5.16;


/**
 * @title ComptrollerCore
 * @dev Storage for the comptroller is at this address, while execution is delegated to the `comptrollerImplementation`.
 * ATokens should reference this contract as their comptroller.
 */
contract Unitroller is UnitrollerAdminStorage, ComptrollerErrorReporter {

    /**
      * @notice Emitted when pendingComptrollerImplementation is changed
      */
    event NewPendingImplementation(address oldPendingImplementation, address newPendingImplementation);

    /**
      * @notice Emitted when pendingComptrollerImplementation is accepted, which means comptroller implementation is updated
      */
    event NewImplementation(address oldImplementation, address newImplementation);

    /**
      * @notice Emitted when pendingAdmin is changed
      */
    event NewPendingAdmin(address oldPendingAdmin, address newPendingAdmin);

    /**
      * @notice Emitted when pendingAdmin is accepted, which means admin is updated
      */
    event NewAdmin(address oldAdmin, address newAdmin);

    constructor() public {
        // Set admin to caller
        admin = msg.sender;
    }

    /*** Admin Functions ***/
    function _setPendingImplementation(address newPendingImplementation) public returns (uint) {

        if (msg.sender != admin) {
            return fail(Error.UNAUTHORIZED, FailureInfo.SET_PENDING_IMPLEMENTATION_OWNER_CHECK);
        }

        address oldPendingImplementation = pendingComptrollerImplementation;

        pendingComptrollerImplementation = newPendingImplementation;

        emit NewPendingImplementation(oldPendingImplementation, pendingComptrollerImplementation);

        return uint(Error.NO_ERROR);
    }

    /**
    * @notice Accepts new implementation of comptroller. msg.sender must be pendingImplementation
    * @dev Admin function for new implementation to accept it's role as implementation
    * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
    */
    function _acceptImplementation() public returns (uint) {
        // Check caller is pendingImplementation and pendingImplementation ≠ address(0)
        if (msg.sender != pendingComptrollerImplementation || pendingComptrollerImplementation == address(0)) {
            return fail(Error.UNAUTHORIZED, FailureInfo.ACCEPT_PENDING_IMPLEMENTATION_ADDRESS_CHECK);
        }

        // Save current values for inclusion in log
        address oldImplementation = comptrollerImplementation;
        address oldPendingImplementation = pendingComptrollerImplementation;

        comptrollerImplementation = pendingComptrollerImplementation;

        pendingComptrollerImplementation = address(0);

        emit NewImplementation(oldImplementation, comptrollerImplementation);
        emit NewPendingImplementation(oldPendingImplementation, pendingComptrollerImplementation);

        return uint(Error.NO_ERROR);
    }


    /**
      * @notice Begins transfer of admin rights. The newPendingAdmin must call `_acceptAdmin` to finalize the transfer.
      * @dev Admin function to begin change of admin. The newPendingAdmin must call `_acceptAdmin` to finalize the transfer.
      * @param newPendingAdmin New pending admin.
      * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
      */
    function _setPendingAdmin(address newPendingAdmin) public returns (uint) {
        // Check caller = admin
        if (msg.sender != admin) {
            return fail(Error.UNAUTHORIZED, FailureInfo.SET_PENDING_ADMIN_OWNER_CHECK);
        }

        // Save current value, if any, for inclusion in log
        address oldPendingAdmin = pendingAdmin;

        // Store pendingAdmin with value newPendingAdmin
        pendingAdmin = newPendingAdmin;

        // Emit NewPendingAdmin(oldPendingAdmin, newPendingAdmin)
        emit NewPendingAdmin(oldPendingAdmin, newPendingAdmin);

        return uint(Error.NO_ERROR);
    }

    /**
      * @notice Accepts transfer of admin rights. msg.sender must be pendingAdmin
      * @dev Admin function for pending admin to accept role and update admin
      * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
      */
    function _acceptAdmin() public returns (uint) {
        // Check caller is pendingAdmin and pendingAdmin ≠ address(0)
        if (msg.sender != pendingAdmin || msg.sender == address(0)) {
            return fail(Error.UNAUTHORIZED, FailureInfo.ACCEPT_ADMIN_PENDING_ADMIN_CHECK);
        }

        // Save current values for inclusion in log
        address oldAdmin = admin;
        address oldPendingAdmin = pendingAdmin;

        // Store admin with value pendingAdmin
        admin = pendingAdmin;

        // Clear the pending value
        pendingAdmin = address(0);

        emit NewAdmin(oldAdmin, admin);
        emit NewPendingAdmin(oldPendingAdmin, pendingAdmin);

        return uint(Error.NO_ERROR);
    }

    /**
     * @dev Delegates execution to an implementation contract.
     * It returns to the external caller whatever the implementation returns
     * or forwards reverts.
     */
    function () payable external {
        // delegate all other functions to current implementation
        (bool success, ) = comptrollerImplementation.delegatecall(msg.data);

        assembly {
              let free_mem_ptr := mload(0x40)
              returndatacopy(free_mem_ptr, 0, returndatasize)

              switch success
              case 0 { revert(free_mem_ptr, returndatasize) }
              default { return(free_mem_ptr, returndatasize) }
        }
    }
}

// File: contracts/Governance/Ars.sol

pragma solidity ^0.5.16;

contract Ars {
    /// @notice EIP-20 token name for this token
    string public constant name = "Aquarius";

    /// @notice EIP-20 token symbol for this token
    string public constant symbol = "ARS";

    /// @notice EIP-20 token decimals for this token
    uint8 public constant decimals = 18;

    /// @notice Total number of tokens in circulation
    uint public constant totalSupply = 1000000000e18; // 1 billion Ars

    /// @notice Allowance amounts on behalf of others
    mapping (address => mapping (address => uint96)) internal allowances;

    /// @notice Official record of token balances for each account
    mapping (address => uint96) internal balances;

    /// @notice A record of each accounts delegate
    mapping (address => address) public delegates;

    /// @notice A checkpoint for marking number of votes from a given block
    struct Checkpoint {
        uint32 fromBlock;
        uint96 votes;
    }

    /// @notice A record of votes checkpoints for each account, by index
    mapping (address => mapping (uint32 => Checkpoint)) public checkpoints;

    /// @notice The number of checkpoints for each account
    mapping (address => uint32) public numCheckpoints;

    /// @notice The EIP-712 typehash for the contract's domain
    bytes32 public constant DOMAIN_TYPEHASH = keccak256("EIP712Domain(string name,uint256 chainId,address verifyingContract)");

    /// @notice The EIP-712 typehash for the delegation struct used by the contract
    bytes32 public constant DELEGATION_TYPEHASH = keccak256("Delegation(address delegatee,uint256 nonce,uint256 expiry)");

    /// @notice A record of states for signing / validating signatures
    mapping (address => uint) public nonces;

    /// @notice An event thats emitted when an account changes its delegate
    event DelegateChanged(address indexed delegator, address indexed fromDelegate, address indexed toDelegate);

    /// @notice An event thats emitted when a delegate account's vote balance changes
    event DelegateVotesChanged(address indexed delegate, uint previousBalance, uint newBalance);

    /// @notice The standard EIP-20 transfer event
    event Transfer(address indexed from, address indexed to, uint256 amount);

    /// @notice The standard EIP-20 approval event
    event Approval(address indexed owner, address indexed spender, uint256 amount);

    /**
     * @notice Construct a new Ars token
     * @param account The initial account to grant all the tokens
     */
    constructor(address account) public {
        balances[account] = uint96(totalSupply);
        emit Transfer(address(0), account, totalSupply);
    }

    /**
     * @notice Get the number of tokens `spender` is approved to spend on behalf of `account`
     * @param account The address of the account holding the funds
     * @param spender The address of the account spending the funds
     * @return The number of tokens approved
     */
    function allowance(address account, address spender) external view returns (uint) {
        return allowances[account][spender];
    }

    /**
     * @notice Approve `spender` to transfer up to `amount` from `src`
     * @dev This will overwrite the approval amount for `spender`
     *  and is subject to issues noted [here](https://eips.ethereum.org/EIPS/eip-20#approve)
     * @param spender The address of the account which may transfer tokens
     * @param rawAmount The number of tokens that are approved (2^256-1 means infinite)
     * @return Whether or not the approval succeeded
     */
    function approve(address spender, uint rawAmount) external returns (bool) {
        uint96 amount;
        if (rawAmount == uint(-1)) {
            amount = uint96(-1);
        } else {
            amount = safe96(rawAmount, "Ars::approve: amount exceeds 96 bits");
        }

        allowances[msg.sender][spender] = amount;

        emit Approval(msg.sender, spender, amount);
        return true;
    }

    /**
     * @notice Get the number of tokens held by the `account`
     * @param account The address of the account to get the balance of
     * @return The number of tokens held
     */
    function balanceOf(address account) external view returns (uint) {
        return balances[account];
    }

    /**
     * @notice Transfer `amount` tokens from `msg.sender` to `dst`
     * @param dst The address of the destination account
     * @param rawAmount The number of tokens to transfer
     * @return Whether or not the transfer succeeded
     */
    function transfer(address dst, uint rawAmount) external returns (bool) {
        uint96 amount = safe96(rawAmount, "Ars::transfer: amount exceeds 96 bits");
        _transferTokens(msg.sender, dst, amount);
        return true;
    }

    /**
     * @notice Transfer `amount` tokens from `src` to `dst`
     * @param src The address of the source account
     * @param dst The address of the destination account
     * @param rawAmount The number of tokens to transfer
     * @return Whether or not the transfer succeeded
     */
    function transferFrom(address src, address dst, uint rawAmount) external returns (bool) {
        address spender = msg.sender;
        uint96 spenderAllowance = allowances[src][spender];
        uint96 amount = safe96(rawAmount, "Ars::approve: amount exceeds 96 bits");

        if (spender != src && spenderAllowance != uint96(-1)) {
            uint96 newAllowance = sub96(spenderAllowance, amount, "Ars::transferFrom: transfer amount exceeds spender allowance");
            allowances[src][spender] = newAllowance;

            emit Approval(src, spender, newAllowance);
        }

        _transferTokens(src, dst, amount);
        return true;
    }

    /**
     * @notice Delegate votes from `msg.sender` to `delegatee`
     * @param delegatee The address to delegate votes to
     */
    function delegate(address delegatee) public {
        return _delegate(msg.sender, delegatee);
    }

    /**
     * @notice Delegates votes from signatory to `delegatee`
     * @param delegatee The address to delegate votes to
     * @param nonce The contract state required to match the signature
     * @param expiry The time at which to expire the signature
     * @param v The recovery byte of the signature
     * @param r Half of the ECDSA signature pair
     * @param s Half of the ECDSA signature pair
     */
    function delegateBySig(address delegatee, uint nonce, uint expiry, uint8 v, bytes32 r, bytes32 s) public {
        bytes32 domainSeparator = keccak256(abi.encode(DOMAIN_TYPEHASH, keccak256(bytes(name)), getChainId(), address(this)));
        bytes32 structHash = keccak256(abi.encode(DELEGATION_TYPEHASH, delegatee, nonce, expiry));
        bytes32 digest = keccak256(abi.encodePacked("\x19\x01", domainSeparator, structHash));
        address signatory = ecrecover(digest, v, r, s);
        require(signatory != address(0), "Ars::delegateBySig: invalid signature");
        require(nonce == nonces[signatory]++, "Ars::delegateBySig: invalid nonce");
        require(now <= expiry, "Ars::delegateBySig: signature expired");
        return _delegate(signatory, delegatee);
    }

    /**
     * @notice Gets the current votes balance for `account`
     * @param account The address to get votes balance
     * @return The number of current votes for `account`
     */
    function getCurrentVotes(address account) external view returns (uint96) {
        uint32 nCheckpoints = numCheckpoints[account];
        return nCheckpoints > 0 ? checkpoints[account][nCheckpoints - 1].votes : 0;
    }

    /**
     * @notice Determine the prior number of votes for an account as of a block number
     * @dev Block number must be a finalized block or else this function will revert to prevent misinformation.
     * @param account The address of the account to check
     * @param blockNumber The block number to get the vote balance at
     * @return The number of votes the account had as of the given block
     */
    function getPriorVotes(address account, uint blockNumber) public view returns (uint96) {
        require(blockNumber < block.number, "Ars::getPriorVotes: not yet determined");

        uint32 nCheckpoints = numCheckpoints[account];
        if (nCheckpoints == 0) {
            return 0;
        }

        // First check most recent balance
        if (checkpoints[account][nCheckpoints - 1].fromBlock <= blockNumber) {
            return checkpoints[account][nCheckpoints - 1].votes;
        }

        // Next check implicit zero balance
        if (checkpoints[account][0].fromBlock > blockNumber) {
            return 0;
        }

        uint32 lower = 0;
        uint32 upper = nCheckpoints - 1;
        while (upper > lower) {
            uint32 center = upper - (upper - lower) / 2; // ceil, avoiding overflow
            Checkpoint memory cp = checkpoints[account][center];
            if (cp.fromBlock == blockNumber) {
                return cp.votes;
            } else if (cp.fromBlock < blockNumber) {
                lower = center;
            } else {
                upper = center - 1;
            }
        }
        return checkpoints[account][lower].votes;
    }

    function _delegate(address delegator, address delegatee) internal {
        address currentDelegate = delegates[delegator];
        uint96 delegatorBalance = balances[delegator];
        delegates[delegator] = delegatee;

        emit DelegateChanged(delegator, currentDelegate, delegatee);

        _moveDelegates(currentDelegate, delegatee, delegatorBalance);
    }

    function _transferTokens(address src, address dst, uint96 amount) internal {
        require(src != address(0), "Ars::_transferTokens: cannot transfer from the zero address");
        require(dst != address(0), "Ars::_transferTokens: cannot transfer to the zero address");

        balances[src] = sub96(balances[src], amount, "Ars::_transferTokens: transfer amount exceeds balance");
        balances[dst] = add96(balances[dst], amount, "Ars::_transferTokens: transfer amount overflows");
        emit Transfer(src, dst, amount);

        _moveDelegates(delegates[src], delegates[dst], amount);
    }

    function _moveDelegates(address srcRep, address dstRep, uint96 amount) internal {
        if (srcRep != dstRep && amount > 0) {
            if (srcRep != address(0)) {
                uint32 srcRepNum = numCheckpoints[srcRep];
                uint96 srcRepOld = srcRepNum > 0 ? checkpoints[srcRep][srcRepNum - 1].votes : 0;
                uint96 srcRepNew = sub96(srcRepOld, amount, "Ars::_moveVotes: vote amount underflows");
                _writeCheckpoint(srcRep, srcRepNum, srcRepOld, srcRepNew);
            }

            if (dstRep != address(0)) {
                uint32 dstRepNum = numCheckpoints[dstRep];
                uint96 dstRepOld = dstRepNum > 0 ? checkpoints[dstRep][dstRepNum - 1].votes : 0;
                uint96 dstRepNew = add96(dstRepOld, amount, "Ars::_moveVotes: vote amount overflows");
                _writeCheckpoint(dstRep, dstRepNum, dstRepOld, dstRepNew);
            }
        }
    }

    function _writeCheckpoint(address delegatee, uint32 nCheckpoints, uint96 oldVotes, uint96 newVotes) internal {
      uint32 blockNumber = safe32(block.number, "Ars::_writeCheckpoint: block number exceeds 32 bits");

      if (nCheckpoints > 0 && checkpoints[delegatee][nCheckpoints - 1].fromBlock == blockNumber) {
          checkpoints[delegatee][nCheckpoints - 1].votes = newVotes;
      } else {
          checkpoints[delegatee][nCheckpoints] = Checkpoint(blockNumber, newVotes);
          numCheckpoints[delegatee] = nCheckpoints + 1;
      }

      emit DelegateVotesChanged(delegatee, oldVotes, newVotes);
    }

    function safe32(uint n, string memory errorMessage) internal pure returns (uint32) {
        require(n < 2**32, errorMessage);
        return uint32(n);
    }

    function safe96(uint n, string memory errorMessage) internal pure returns (uint96) {
        require(n < 2**96, errorMessage);
        return uint96(n);
    }

    function add96(uint96 a, uint96 b, string memory errorMessage) internal pure returns (uint96) {
        uint96 c = a + b;
        require(c >= a, errorMessage);
        return c;
    }

    function sub96(uint96 a, uint96 b, string memory errorMessage) internal pure returns (uint96) {
        require(b <= a, errorMessage);
        return a - b;
    }

    function getChainId() internal pure returns (uint) {
        uint256 chainId;
        assembly { chainId := chainid() }
        return chainId;
    }
}

// File: contracts/Comptroller.sol

pragma solidity ^0.5.16;








/**
 * @title Aquarius's Comptroller Contract
 * @author Aquarius
 */
contract Comptroller is ComptrollerV7Storage, ComptrollerInterface, ComptrollerErrorReporter, ExponentialNoError {
    /// @notice Emitted when an admin supports a market
    event MarketListed(AToken aToken);

    /// @notice Emitted when an account enters a market
    event MarketEntered(AToken aToken, address account);

    /// @notice Emitted when an account exits a market
    event MarketExited(AToken aToken, address account);

    /// @notice Emitted when close factor is changed by admin
    event NewCloseFactor(uint oldCloseFactorMantissa, uint newCloseFactorMantissa);

    /// @notice Emitted when a collateral factor is changed by admin
    event NewCollateralFactor(AToken aToken, uint oldCollateralFactorMantissa, uint newCollateralFactorMantissa);

    /// @notice Emitted when liquidation incentive is changed by admin
    event NewLiquidationIncentive(uint oldLiquidationIncentiveMantissa, uint newLiquidationIncentiveMantissa);

    /// @notice Emitted when price oracle is changed
    event NewPriceOracle(PriceOracle oldPriceOracle, PriceOracle newPriceOracle);

    /// @notice Emitted when pause guardian is changed
    event NewPauseGuardian(address oldPauseGuardian, address newPauseGuardian);

    /// @notice Emitted when an action is paused globally
    event ActionPaused(string action, bool pauseState);

    /// @notice Emitted when an action is paused on a market
    event ActionPaused(AToken aToken, string action, bool pauseState);

    /// @notice Emitted when a new borrow-side ARS speed is calculated for a market
    event ArsBorrowSpeedUpdated(AToken indexed aToken, uint newSpeed);

    /// @notice Emitted when a new supply-side ARS speed is calculated for a market
    event ArsSupplySpeedUpdated(AToken indexed aToken, uint newSpeed);

    /// @notice Emitted when a new ARS speed is set for a contributor
    event ContributorArsSpeedUpdated(address indexed contributor, uint newSpeed);

    /// @notice Emitted when ARS is distributed to a supplier
    event DistributedSupplierArs(AToken indexed aToken, address indexed supplier, uint arsDelta, uint arsSupplyIndex);

    /// @notice Emitted when ARS is distributed to a borrower
    event DistributedBorrowerArs(AToken indexed aToken, address indexed borrower, uint arsDelta, uint arsBorrowIndex);

    /// @notice Emitted when borrow cap for a aToken is changed
    event NewBorrowCap(AToken indexed aToken, uint newBorrowCap);

    /// @notice Emitted when borrow cap guardian is changed
    event NewBorrowCapGuardian(address oldBorrowCapGuardian, address newBorrowCapGuardian);

    /// @notice Emitted when ARS is granted by admin
    event ArsGranted(address recipient, uint amount);

    /// @notice Emitted when ARS accrued for a user has been manually adjusted.
    event ArsAccruedAdjusted(address indexed user, uint oldArsAccrued, uint newArsAccrued);

    /// @notice Emitted when ARS receivable for a user has been updated.
    event ArsReceivableUpdated(address indexed user, uint oldArsReceivable, uint newArsReceivable);

    /// @notice The initial ARS index for a market
    uint224 public constant arsInitialIndex = 1e36;

    // closeFactorMantissa must be strictly greater than this value
    uint internal constant closeFactorMinMantissa = 0.05e18; // 0.05

    // closeFactorMantissa must not exceed this value
    uint internal constant closeFactorMaxMantissa = 0.9e18; // 0.9

    // No collateralFactorMantissa may exceed this value
    uint internal constant collateralFactorMaxMantissa = 0.9e18; // 0.9

    constructor() public {
        admin = msg.sender;
    }

    /*** Assets You Are In ***/

    /**
     * @notice Returns the assets an account has entered
     * @param account The address of the account to pull assets for
     * @return A dynamic list with the assets the account has entered
     */
    function getAssetsIn(address account) external view returns (AToken[] memory) {
        AToken[] memory assetsIn = accountAssets[account];

        return assetsIn;
    }

    /**
     * @notice Returns whether the given account is entered in the given asset
     * @param account The address of the account to check
     * @param aToken The aToken to check
     * @return True if the account is in the asset, otherwise false.
     */
    function checkMembership(address account, AToken aToken) external view returns (bool) {
        return markets[address(aToken)].accountMembership[account];
    }

    /**
     * @notice Add assets to be included in account liquidity calculation
     * @param aTokens The list of addresses of the aToken markets to be enabled
     * @return Success indicator for whether each corresponding market was entered
     */
    function enterMarkets(address[] memory aTokens) public returns (uint[] memory) {
        uint len = aTokens.length;

        uint[] memory results = new uint[](len);
        for (uint i = 0; i < len; i++) {
            AToken aToken = AToken(aTokens[i]);

            results[i] = uint(addToMarketInternal(aToken, msg.sender));
        }

        return results;
    }

    /**
     * @notice Add the market to the borrower's "assets in" for liquidity calculations
     * @param aToken The market to enter
     * @param borrower The address of the account to modify
     * @return Success indicator for whether the market was entered
     */
    function addToMarketInternal(AToken aToken, address borrower) internal returns (Error) {
        Market storage marketToJoin = markets[address(aToken)];

        if (!marketToJoin.isListed) {
            // market is not listed, cannot join
            return Error.MARKET_NOT_LISTED;
        }

        if (marketToJoin.accountMembership[borrower] == true) {
            // already joined
            return Error.NO_ERROR;
        }

        // survived the gauntlet, add to list
        // NOTE: we store these somewhat redundantly as a significant optimization
        //  this avoids having to iterate through the list for the most common use cases
        //  that is, only when we need to perform liquidity checks
        //  and not whenever we want to check if an account is in a particular market
        marketToJoin.accountMembership[borrower] = true;
        accountAssets[borrower].push(aToken);

        emit MarketEntered(aToken, borrower);

        return Error.NO_ERROR;
    }

    /**
     * @notice Removes asset from sender's account liquidity calculation
     * @dev Sender must not have an outstanding borrow balance in the asset,
     *  or be providing necessary collateral for an outstanding borrow.
     * @param aTokenAddress The address of the asset to be removed
     * @return Whether or not the account successfully exited the market
     */
    function exitMarket(address aTokenAddress) external returns (uint) {
        AToken aToken = AToken(aTokenAddress);
        /* Get sender tokensHeld and amountOwed underlying from the aToken */
        (uint oErr, uint tokensHeld, uint amountOwed, ) = aToken.getAccountSnapshot(msg.sender);
        require(oErr == 0, "exitMarket: getAccountSnapshot failed"); // semi-opaque error code

        /* Fail if the sender has a borrow balance */
        if (amountOwed != 0) {
            return fail(Error.NONZERO_BORROW_BALANCE, FailureInfo.EXIT_MARKET_BALANCE_OWED);
        }

        /* Fail if the sender is not permitted to redeem all of their tokens */
        uint allowed = redeemAllowedInternal(aTokenAddress, msg.sender, tokensHeld);
        if (allowed != 0) {
            return failOpaque(Error.REJECTION, FailureInfo.EXIT_MARKET_REJECTION, allowed);
        }

        Market storage marketToExit = markets[address(aToken)];

        /* Return true if the sender is not already ‘in’ the market */
        if (!marketToExit.accountMembership[msg.sender]) {
            return uint(Error.NO_ERROR);
        }

        /* Set aToken account membership to false */
        delete marketToExit.accountMembership[msg.sender];

        /* Delete aToken from the account’s list of assets */
        // load into memory for faster iteration
        AToken[] memory userAssetList = accountAssets[msg.sender];
        uint len = userAssetList.length;
        uint assetIndex = len;
        for (uint i = 0; i < len; i++) {
            if (userAssetList[i] == aToken) {
                assetIndex = i;
                break;
            }
        }

        // We *must* have found the asset in the list or our redundant data structure is broken
        assert(assetIndex < len);

        // copy last item in list to location of item to be removed, reduce length by 1
        AToken[] storage storedList = accountAssets[msg.sender];
        storedList[assetIndex] = storedList[storedList.length - 1];
        storedList.length--;

        emit MarketExited(aToken, msg.sender);

        return uint(Error.NO_ERROR);
    }

    /*** Policy Hooks ***/

    /**
     * @notice Checks if the account should be allowed to mint tokens in the given market
     * @param aToken The market to verify the mint against
     * @param minter The account which would get the minted tokens
     * @param mintAmount The amount of underlying being supplied to the market in exchange for tokens
     * @return 0 if the mint is allowed, otherwise a semi-opaque error code (See ErrorReporter.sol)
     */
    function mintAllowed(address aToken, address minter, uint mintAmount) external returns (uint) {
        // Pausing is a very serious situation - we revert to sound the alarms
        require(!mintGuardianPaused[aToken], "mint is paused");

        // Shh - currently unused
        minter;
        mintAmount;

        if (!markets[aToken].isListed) {
            return uint(Error.MARKET_NOT_LISTED);
        }

        // Keep the flywheel moving
        updateArsSupplyIndex(aToken);
        distributeSupplierArs(aToken, minter);

        return uint(Error.NO_ERROR);
    }

    /**
     * @notice Validates mint and reverts on rejection. May emit logs.
     * @param aToken Asset being minted
     * @param minter The address minting the tokens
     * @param actualMintAmount The amount of the underlying asset being minted
     * @param mintTokens The number of tokens being minted
     */
    function mintVerify(address aToken, address minter, uint actualMintAmount, uint mintTokens) external {
        // Shh - currently unused
        aToken;
        minter;
        actualMintAmount;
        mintTokens;

        // Shh - we don't ever want this hook to be marked pure
        if (false) {
            maxAssets = maxAssets;
        }
    }

    /**
     * @notice Checks if the account should be allowed to redeem tokens in the given market
     * @param aToken The market to verify the redeem against
     * @param redeemer The account which would redeem the tokens
     * @param redeemTokens The number of aTokens to exchange for the underlying asset in the market
     * @return 0 if the redeem is allowed, otherwise a semi-opaque error code (See ErrorReporter.sol)
     */
    function redeemAllowed(address aToken, address redeemer, uint redeemTokens) external returns (uint) {
        uint allowed = redeemAllowedInternal(aToken, redeemer, redeemTokens);
        if (allowed != uint(Error.NO_ERROR)) {
            return allowed;
        }

        // Keep the flywheel moving
        updateArsSupplyIndex(aToken);
        distributeSupplierArs(aToken, redeemer);

        return uint(Error.NO_ERROR);
    }

    function redeemAllowedInternal(address aToken, address redeemer, uint redeemTokens) internal view returns (uint) {
        if (!markets[aToken].isListed) {
            return uint(Error.MARKET_NOT_LISTED);
        }

        /* If the redeemer is not 'in' the market, then we can bypass the liquidity check */
        if (!markets[aToken].accountMembership[redeemer]) {
            return uint(Error.NO_ERROR);
        }

        /* Otherwise, perform a hypothetical liquidity check to guard against shortfall */
        (Error err, , uint shortfall) = getHypotheticalAccountLiquidityInternal(redeemer, AToken(aToken), redeemTokens, 0);
        if (err != Error.NO_ERROR) {
            return uint(err);
        }
        if (shortfall > 0) {
            return uint(Error.INSUFFICIENT_LIQUIDITY);
        }

        return uint(Error.NO_ERROR);
    }

    /**
     * @notice Validates redeem and reverts on rejection. May emit logs.
     * @param aToken Asset being redeemed
     * @param redeemer The address redeeming the tokens
     * @param redeemAmount The amount of the underlying asset being redeemed
     * @param redeemTokens The number of tokens being redeemed
     */
    function redeemVerify(address aToken, address redeemer, uint redeemAmount, uint redeemTokens) external {
        // Shh - currently unused
        aToken;
        redeemer;

        // Require tokens is zero or amount is also zero
        if (redeemTokens == 0 && redeemAmount > 0) {
            revert("redeemTokens zero");
        }
    }

    /**
     * @notice Checks if the account should be allowed to borrow the underlying asset of the given market
     * @param aToken The market to verify the borrow against
     * @param borrower The account which would borrow the asset
     * @param borrowAmount The amount of underlying the account would borrow
     * @return 0 if the borrow is allowed, otherwise a semi-opaque error code (See ErrorReporter.sol)
     */
    function borrowAllowed(address aToken, address borrower, uint borrowAmount) external returns (uint) {
        // Pausing is a very serious situation - we revert to sound the alarms
        require(!borrowGuardianPaused[aToken], "borrow is paused");

        if (!markets[aToken].isListed) {
            return uint(Error.MARKET_NOT_LISTED);
        }

        if (!markets[aToken].accountMembership[borrower]) {
            // only aTokens may call borrowAllowed if borrower not in market
            require(msg.sender == aToken, "sender must be aToken");

            // attempt to add borrower to the market
            Error err = addToMarketInternal(AToken(msg.sender), borrower);
            if (err != Error.NO_ERROR) {
                return uint(err);
            }

            // it should be impossible to break the important invariant
            assert(markets[aToken].accountMembership[borrower]);
        }

        if (oracle.getUnderlyingPrice(AToken(aToken)) == 0) {
            return uint(Error.PRICE_ERROR);
        }


        uint borrowCap = borrowCaps[aToken];
        // Borrow cap of 0 corresponds to unlimited borrowing
        if (borrowCap != 0) {
            uint totalBorrows = AToken(aToken).totalBorrows();
            uint nextTotalBorrows = add_(totalBorrows, borrowAmount);
            require(nextTotalBorrows < borrowCap, "market borrow cap reached");
        }

        (Error err, , uint shortfall) = getHypotheticalAccountLiquidityInternal(borrower, AToken(aToken), 0, borrowAmount);
        if (err != Error.NO_ERROR) {
            return uint(err);
        }
        if (shortfall > 0) {
            return uint(Error.INSUFFICIENT_LIQUIDITY);
        }

        // Keep the flywheel moving
        Exp memory borrowIndex = Exp({mantissa: AToken(aToken).borrowIndex()});
        updateArsBorrowIndex(aToken, borrowIndex);
        distributeBorrowerArs(aToken, borrower, borrowIndex);

        return uint(Error.NO_ERROR);
    }

    /**
     * @notice Validates borrow and reverts on rejection. May emit logs.
     * @param aToken Asset whose underlying is being borrowed
     * @param borrower The address borrowing the underlying
     * @param borrowAmount The amount of the underlying asset requested to borrow
     */
    function borrowVerify(address aToken, address borrower, uint borrowAmount) external {
        // Shh - currently unused
        aToken;
        borrower;
        borrowAmount;

        // Shh - we don't ever want this hook to be marked pure
        if (false) {
            maxAssets = maxAssets;
        }
    }

    /**
     * @notice Checks if the account should be allowed to repay a borrow in the given market
     * @param aToken The market to verify the repay against
     * @param payer The account which would repay the asset
     * @param borrower The account which would borrowed the asset
     * @param repayAmount The amount of the underlying asset the account would repay
     * @return 0 if the repay is allowed, otherwise a semi-opaque error code (See ErrorReporter.sol)
     */
    function repayBorrowAllowed(
        address aToken,
        address payer,
        address borrower,
        uint repayAmount) external returns (uint) {
        // Shh - currently unused
        payer;
        borrower;
        repayAmount;

        if (!markets[aToken].isListed) {
            return uint(Error.MARKET_NOT_LISTED);
        }

        // Keep the flywheel moving
        Exp memory borrowIndex = Exp({mantissa: AToken(aToken).borrowIndex()});
        updateArsBorrowIndex(aToken, borrowIndex);
        distributeBorrowerArs(aToken, borrower, borrowIndex);

        return uint(Error.NO_ERROR);
    }

    /**
     * @notice Validates repayBorrow and reverts on rejection. May emit logs.
     * @param aToken Asset being repaid
     * @param payer The address repaying the borrow
     * @param borrower The address of the borrower
     * @param actualRepayAmount The amount of underlying being repaid
     */
    function repayBorrowVerify(
        address aToken,
        address payer,
        address borrower,
        uint actualRepayAmount,
        uint borrowerIndex) external {
        // Shh - currently unused
        aToken;
        payer;
        borrower;
        actualRepayAmount;
        borrowerIndex;

        // Shh - we don't ever want this hook to be marked pure
        if (false) {
            maxAssets = maxAssets;
        }
    }

    /**
     * @notice Checks if the liquidation should be allowed to occur
     * @param aTokenBorrowed Asset which was borrowed by the borrower
     * @param aTokenCollateral Asset which was used as collateral and will be seized
     * @param liquidator The address repaying the borrow and seizing the collateral
     * @param borrower The address of the borrower
     * @param repayAmount The amount of underlying being repaid
     */
    function liquidateBorrowAllowed(
        address aTokenBorrowed,
        address aTokenCollateral,
        address liquidator,
        address borrower,
        uint repayAmount) external returns (uint) {
        // Shh - currently unused
        liquidator;

        if (!markets[aTokenBorrowed].isListed || !markets[aTokenCollateral].isListed) {
            return uint(Error.MARKET_NOT_LISTED);
        }

        uint borrowBalance = AToken(aTokenBorrowed).borrowBalanceStored(borrower);

        /* allow accounts to be liquidated if the market is deprecated */
        if (isDeprecated(AToken(aTokenBorrowed))) {
            require(borrowBalance >= repayAmount, "Can not repay more than the total borrow");
        } else {
            /* The borrower must have shortfall in order to be liquidatable */
            (Error err, , uint shortfall) = getAccountLiquidityInternal(borrower);
            if (err != Error.NO_ERROR) {
                return uint(err);
            }

            if (shortfall == 0) {
                return uint(Error.INSUFFICIENT_SHORTFALL);
            }

            /* The liquidator may not repay more than what is allowed by the closeFactor */
            uint maxClose = mul_ScalarTruncate(Exp({mantissa: closeFactorMantissa}), borrowBalance);
            if (repayAmount > maxClose) {
                return uint(Error.TOO_MUCH_REPAY);
            }
        }
        return uint(Error.NO_ERROR);
    }

    /**
     * @notice Validates liquidateBorrow and reverts on rejection. May emit logs.
     * @param aTokenBorrowed Asset which was borrowed by the borrower
     * @param aTokenCollateral Asset which was used as collateral and will be seized
     * @param liquidator The address repaying the borrow and seizing the collateral
     * @param borrower The address of the borrower
     * @param actualRepayAmount The amount of underlying being repaid
     */
    function liquidateBorrowVerify(
        address aTokenBorrowed,
        address aTokenCollateral,
        address liquidator,
        address borrower,
        uint actualRepayAmount,
        uint seizeTokens) external {
        // Shh - currently unused
        aTokenBorrowed;
        aTokenCollateral;
        liquidator;
        borrower;
        actualRepayAmount;
        seizeTokens;

        // Shh - we don't ever want this hook to be marked pure
        if (false) {
            maxAssets = maxAssets;
        }
    }

    /**
     * @notice Checks if the seizing of assets should be allowed to occur
     * @param aTokenCollateral Asset which was used as collateral and will be seized
     * @param aTokenBorrowed Asset which was borrowed by the borrower
     * @param liquidator The address repaying the borrow and seizing the collateral
     * @param borrower The address of the borrower
     * @param seizeTokens The number of collateral tokens to seize
     */
    function seizeAllowed(
        address aTokenCollateral,
        address aTokenBorrowed,
        address liquidator,
        address borrower,
        uint seizeTokens) external returns (uint) {
        // Pausing is a very serious situation - we revert to sound the alarms
        require(!seizeGuardianPaused, "seize is paused");

        // Shh - currently unused
        seizeTokens;

        if (!markets[aTokenCollateral].isListed || !markets[aTokenBorrowed].isListed) {
            return uint(Error.MARKET_NOT_LISTED);
        }

        if (AToken(aTokenCollateral).comptroller() != AToken(aTokenBorrowed).comptroller()) {
            return uint(Error.COMPTROLLER_MISMATCH);
        }

        // Keep the flywheel moving
        updateArsSupplyIndex(aTokenCollateral);
        distributeSupplierArs(aTokenCollateral, borrower);
        distributeSupplierArs(aTokenCollateral, liquidator);

        return uint(Error.NO_ERROR);
    }

    /**
     * @notice Validates seize and reverts on rejection. May emit logs.
     * @param aTokenCollateral Asset which was used as collateral and will be seized
     * @param aTokenBorrowed Asset which was borrowed by the borrower
     * @param liquidator The address repaying the borrow and seizing the collateral
     * @param borrower The address of the borrower
     * @param seizeTokens The number of collateral tokens to seize
     */
    function seizeVerify(
        address aTokenCollateral,
        address aTokenBorrowed,
        address liquidator,
        address borrower,
        uint seizeTokens) external {
        // Shh - currently unused
        aTokenCollateral;
        aTokenBorrowed;
        liquidator;
        borrower;
        seizeTokens;

        // Shh - we don't ever want this hook to be marked pure
        if (false) {
            maxAssets = maxAssets;
        }
    }

    /**
     * @notice Checks if the account should be allowed to transfer tokens in the given market
     * @param aToken The market to verify the transfer against
     * @param src The account which sources the tokens
     * @param dst The account which receives the tokens
     * @param transferTokens The number of aTokens to transfer
     * @return 0 if the transfer is allowed, otherwise a semi-opaque error code (See ErrorReporter.sol)
     */
    function transferAllowed(address aToken, address src, address dst, uint transferTokens) external returns (uint) {
        // Pausing is a very serious situation - we revert to sound the alarms
        require(!transferGuardianPaused, "transfer is paused");

        // Currently the only consideration is whether or not
        //  the src is allowed to redeem this many tokens
        uint allowed = redeemAllowedInternal(aToken, src, transferTokens);
        if (allowed != uint(Error.NO_ERROR)) {
            return allowed;
        }

        // Keep the flywheel moving
        updateArsSupplyIndex(aToken);
        distributeSupplierArs(aToken, src);
        distributeSupplierArs(aToken, dst);

        return uint(Error.NO_ERROR);
    }

    /**
     * @notice Validates transfer and reverts on rejection. May emit logs.
     * @param aToken Asset being transferred
     * @param src The account which sources the tokens
     * @param dst The account which receives the tokens
     * @param transferTokens The number of aTokens to transfer
     */
    function transferVerify(address aToken, address src, address dst, uint transferTokens) external {
        // Shh - currently unused
        aToken;
        src;
        dst;
        transferTokens;

        // Shh - we don't ever want this hook to be marked pure
        if (false) {
            maxAssets = maxAssets;
        }
    }

    /*** Liquidity/Liquidation Calculations ***/

    /**
     * @dev Local vars for avoiding stack-depth limits in calculating account liquidity.
     *  Note that `aTokenBalance` is the number of aTokens the account owns in the market,
     *  whereas `borrowBalance` is the amount of underlying that the account has borrowed.
     */
    struct AccountLiquidityLocalVars {
        uint sumCollateral;
        uint sumBorrowPlusEffects;
        uint aTokenBalance;
        uint borrowBalance;
        uint exchangeRateMantissa;
        uint oraclePriceMantissa;
        Exp collateralFactor;
        Exp exchangeRate;
        Exp oraclePrice;
        Exp tokensToDenom;
    }

    /**
     * @notice Determine the current account liquidity wrt collateral requirements
     * @return (possible error code (semi-opaque),
                account liquidity in excess of collateral requirements,
     *          account shortfall below collateral requirements)
     */
    function getAccountLiquidity(address account) public view returns (uint, uint, uint) {
        (Error err, uint liquidity, uint shortfall) = getHypotheticalAccountLiquidityInternal(account, AToken(0), 0, 0);

        return (uint(err), liquidity, shortfall);
    }

    /**
     * @notice Determine the current account liquidity wrt collateral requirements
     * @return (possible error code,
                account liquidity in excess of collateral requirements,
     *          account shortfall below collateral requirements)
     */
    function getAccountLiquidityInternal(address account) internal view returns (Error, uint, uint) {
        return getHypotheticalAccountLiquidityInternal(account, AToken(0), 0, 0);
    }

    /**
     * @notice Determine what the account liquidity would be if the given amounts were redeemed/borrowed
     * @param aTokenModify The market to hypothetically redeem/borrow in
     * @param account The account to determine liquidity for
     * @param redeemTokens The number of tokens to hypothetically redeem
     * @param borrowAmount The amount of underlying to hypothetically borrow
     * @return (possible error code (semi-opaque),
                hypothetical account liquidity in excess of collateral requirements,
     *          hypothetical account shortfall below collateral requirements)
     */
    function getHypotheticalAccountLiquidity(
        address account,
        address aTokenModify,
        uint redeemTokens,
        uint borrowAmount) public view returns (uint, uint, uint) {
        (Error err, uint liquidity, uint shortfall) = getHypotheticalAccountLiquidityInternal(account, AToken(aTokenModify), redeemTokens, borrowAmount);
        return (uint(err), liquidity, shortfall);
    }

    /**
     * @notice Determine what the account liquidity would be if the given amounts were redeemed/borrowed
     * @param aTokenModify The market to hypothetically redeem/borrow in
     * @param account The account to determine liquidity for
     * @param redeemTokens The number of tokens to hypothetically redeem
     * @param borrowAmount The amount of underlying to hypothetically borrow
     * @dev Note that we calculate the exchangeRateStored for each collateral aToken using stored data,
     *  without calculating accumulated interest.
     * @return (possible error code,
                hypothetical account liquidity in excess of collateral requirements,
     *          hypothetical account shortfall below collateral requirements)
     */
    function getHypotheticalAccountLiquidityInternal(
        address account,
        AToken aTokenModify,
        uint redeemTokens,
        uint borrowAmount) internal view returns (Error, uint, uint) {

        AccountLiquidityLocalVars memory vars; // Holds all our calculation results
        uint oErr;

        // For each asset the account is in
        AToken[] memory assets = accountAssets[account];
        for (uint i = 0; i < assets.length; i++) {
            AToken asset = assets[i];

            // Read the balances and exchange rate from the aToken
            (oErr, vars.aTokenBalance, vars.borrowBalance, vars.exchangeRateMantissa) = asset.getAccountSnapshot(account);
            if (oErr != 0) { // semi-opaque error code, we assume NO_ERROR == 0 is invariant between upgrades
                return (Error.SNAPSHOT_ERROR, 0, 0);
            }
            vars.collateralFactor = Exp({mantissa: markets[address(asset)].collateralFactorMantissa});
            vars.exchangeRate = Exp({mantissa: vars.exchangeRateMantissa});

            // Get the normalized price of the asset
            vars.oraclePriceMantissa = oracle.getUnderlyingPrice(asset);
            if (vars.oraclePriceMantissa == 0) {
                return (Error.PRICE_ERROR, 0, 0);
            }
            vars.oraclePrice = Exp({mantissa: vars.oraclePriceMantissa});

            // Pre-compute a conversion factor from tokens -> ether (normalized price value)
            vars.tokensToDenom = mul_(mul_(vars.collateralFactor, vars.exchangeRate), vars.oraclePrice);

            // sumCollateral += tokensToDenom * aTokenBalance
            vars.sumCollateral = mul_ScalarTruncateAddUInt(vars.tokensToDenom, vars.aTokenBalance, vars.sumCollateral);

            // sumBorrowPlusEffects += oraclePrice * borrowBalance
            vars.sumBorrowPlusEffects = mul_ScalarTruncateAddUInt(vars.oraclePrice, vars.borrowBalance, vars.sumBorrowPlusEffects);

            // Calculate effects of interacting with aTokenModify
            if (asset == aTokenModify) {
                // redeem effect
                // sumBorrowPlusEffects += tokensToDenom * redeemTokens
                vars.sumBorrowPlusEffects = mul_ScalarTruncateAddUInt(vars.tokensToDenom, redeemTokens, vars.sumBorrowPlusEffects);

                // borrow effect
                // sumBorrowPlusEffects += oraclePrice * borrowAmount
                vars.sumBorrowPlusEffects = mul_ScalarTruncateAddUInt(vars.oraclePrice, borrowAmount, vars.sumBorrowPlusEffects);
            }
        }

        // These are safe, as the underflow condition is checked first
        if (vars.sumCollateral > vars.sumBorrowPlusEffects) {
            return (Error.NO_ERROR, vars.sumCollateral - vars.sumBorrowPlusEffects, 0);
        } else {
            return (Error.NO_ERROR, 0, vars.sumBorrowPlusEffects - vars.sumCollateral);
        }
    }

    /**
     * @notice Calculate number of tokens of collateral asset to seize given an underlying amount
     * @dev Used in liquidation (called in aToken.liquidateBorrowFresh)
     * @param aTokenBorrowed The address of the borrowed aToken
     * @param aTokenCollateral The address of the collateral aToken
     * @param actualRepayAmount The amount of aTokenBorrowed underlying to convert into aTokenCollateral tokens
     * @return (errorCode, number of aTokenCollateral tokens to be seized in a liquidation)
     */
    function liquidateCalculateSeizeTokens(address aTokenBorrowed, address aTokenCollateral, uint actualRepayAmount) external view returns (uint, uint) {
        /* Read oracle prices for borrowed and collateral markets */
        uint priceBorrowedMantissa = oracle.getUnderlyingPrice(AToken(aTokenBorrowed));
        uint priceCollateralMantissa = oracle.getUnderlyingPrice(AToken(aTokenCollateral));
        if (priceBorrowedMantissa == 0 || priceCollateralMantissa == 0) {
            return (uint(Error.PRICE_ERROR), 0);
        }

        /*
         * Get the exchange rate and calculate the number of collateral tokens to seize:
         *  seizeAmount = actualRepayAmount * liquidationIncentive * priceBorrowed / priceCollateral
         *  seizeTokens = seizeAmount / exchangeRate
         *   = actualRepayAmount * (liquidationIncentive * priceBorrowed) / (priceCollateral * exchangeRate)
         */
        uint exchangeRateMantissa = AToken(aTokenCollateral).exchangeRateStored(); // Note: reverts on error
        uint seizeTokens;
        Exp memory numerator;
        Exp memory denominator;
        Exp memory ratio;

        numerator = mul_(Exp({mantissa: liquidationIncentiveMantissa}), Exp({mantissa: priceBorrowedMantissa}));
        denominator = mul_(Exp({mantissa: priceCollateralMantissa}), Exp({mantissa: exchangeRateMantissa}));
        ratio = div_(numerator, denominator);

        seizeTokens = mul_ScalarTruncate(ratio, actualRepayAmount);

        return (uint(Error.NO_ERROR), seizeTokens);
    }

    /*** Admin Functions ***/

    /**
      * @notice Sets a new price oracle for the comptroller
      * @dev Admin function to set a new price oracle
      * @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
      */
    function _setPriceOracle(PriceOracle newOracle) public returns (uint) {
        // Check caller is admin
        if (msg.sender != admin) {
            return fail(Error.UNAUTHORIZED, FailureInfo.SET_PRICE_ORACLE_OWNER_CHECK);
        }

        // Track the old oracle for the comptroller
        PriceOracle oldOracle = oracle;

        // Set comptroller's oracle to newOracle
        oracle = newOracle;

        // Emit NewPriceOracle(oldOracle, newOracle)
        emit NewPriceOracle(oldOracle, newOracle);

        return uint(Error.NO_ERROR);
    }

    /**
      * @notice Sets the closeFactor used when liquidating borrows
      * @dev Admin function to set closeFactor
      * @param newCloseFactorMantissa New close factor, scaled by 1e18
      * @return uint 0=success, otherwise a failure
      */
    function _setCloseFactor(uint newCloseFactorMantissa) external returns (uint) {
        // Check caller is admin
    	require(msg.sender == admin, "only admin can set close factor");

        uint oldCloseFactorMantissa = closeFactorMantissa;
        closeFactorMantissa = newCloseFactorMantissa;
        emit NewCloseFactor(oldCloseFactorMantissa, closeFactorMantissa);

        return uint(Error.NO_ERROR);
    }

    /**
      * @notice Sets the collateralFactor for a market
      * @dev Admin function to set per-market collateralFactor
      * @param aToken The market to set the factor on
      * @param newCollateralFactorMantissa The new collateral factor, scaled by 1e18
      * @return uint 0=success, otherwise a failure. (See ErrorReporter for details)
      */
    function _setCollateralFactor(AToken aToken, uint newCollateralFactorMantissa) external returns (uint) {
        // Check caller is admin
        if (msg.sender != admin) {
            return fail(Error.UNAUTHORIZED, FailureInfo.SET_COLLATERAL_FACTOR_OWNER_CHECK);
        }

        // Verify market is listed
        Market storage market = markets[address(aToken)];
        if (!market.isListed) {
            return fail(Error.MARKET_NOT_LISTED, FailureInfo.SET_COLLATERAL_FACTOR_NO_EXISTS);
        }

        Exp memory newCollateralFactorExp = Exp({mantissa: newCollateralFactorMantissa});

        // Check collateral factor <= 0.9
        Exp memory highLimit = Exp({mantissa: collateralFactorMaxMantissa});
        if (lessThanExp(highLimit, newCollateralFactorExp)) {
            return fail(Error.INVALID_COLLATERAL_FACTOR, FailureInfo.SET_COLLATERAL_FACTOR_VALIDATION);
        }

        // If collateral factor != 0, fail if price == 0
        if (newCollateralFactorMantissa != 0 && oracle.getUnderlyingPrice(aToken) == 0) {
            return fail(Error.PRICE_ERROR, FailureInfo.SET_COLLATERAL_FACTOR_WITHOUT_PRICE);
        }

        // Set market's collateral factor to new collateral factor, remember old value
        uint oldCollateralFactorMantissa = market.collateralFactorMantissa;
        market.collateralFactorMantissa = newCollateralFactorMantissa;

        // Emit event with asset, old collateral factor, and new collateral factor
        emit NewCollateralFactor(aToken, oldCollateralFactorMantissa, newCollateralFactorMantissa);

        return uint(Error.NO_ERROR);
    }

    /**
      * @notice Sets liquidationIncentive
      * @dev Admin function to set liquidationIncentive
      * @param newLiquidationIncentiveMantissa New liquidationIncentive scaled by 1e18
      * @return uint 0=success, otherwise a failure. (See ErrorReporter for details)
      */
    function _setLiquidationIncentive(uint newLiquidationIncentiveMantissa) external returns (uint) {
        // Check caller is admin
        if (msg.sender != admin) {
            return fail(Error.UNAUTHORIZED, FailureInfo.SET_LIQUIDATION_INCENTIVE_OWNER_CHECK);
        }

        // Save current value for use in log
        uint oldLiquidationIncentiveMantissa = liquidationIncentiveMantissa;

        // Set liquidation incentive to new incentive
        liquidationIncentiveMantissa = newLiquidationIncentiveMantissa;

        // Emit event with old incentive, new incentive
        emit NewLiquidationIncentive(oldLiquidationIncentiveMantissa, newLiquidationIncentiveMantissa);

        return uint(Error.NO_ERROR);
    }

    /**
      * @notice Add the market to the markets mapping and set it as listed
      * @dev Admin function to set isListed and add support for the market
      * @param aToken The address of the market (token) to list
      * @return uint 0=success, otherwise a failure. (See enum Error for details)
      */
    function _supportMarket(AToken aToken) external returns (uint) {
        if (msg.sender != admin) {
            return fail(Error.UNAUTHORIZED, FailureInfo.SUPPORT_MARKET_OWNER_CHECK);
        }

        if (markets[address(aToken)].isListed) {
            return fail(Error.MARKET_ALREADY_LISTED, FailureInfo.SUPPORT_MARKET_EXISTS);
        }

        aToken.isAToken(); // Sanity check to make sure its really a AToken

        // Note that isComped is not in active use anymore
        markets[address(aToken)] = Market({isListed: true, isComped: false, collateralFactorMantissa: 0});

        _addMarketInternal(address(aToken));
        _initializeMarket(address(aToken));

        emit MarketListed(aToken);

        return uint(Error.NO_ERROR);
    }

    function _addMarketInternal(address aToken) internal {
        for (uint i = 0; i < allMarkets.length; i ++) {
            require(allMarkets[i] != AToken(aToken), "market already added");
        }
        allMarkets.push(AToken(aToken));
    }

    function _initializeMarket(address aToken) internal {
        uint32 blockNumber = safe32(getBlockNumber(), "block number exceeds 32 bits");

        ArsMarketState storage supplyState = arsSupplyState[aToken];
        ArsMarketState storage borrowState = arsBorrowState[aToken];

        /*
         * Update market state indices
         */
        if (supplyState.index == 0) {
            // Initialize supply state index with default value
            supplyState.index = arsInitialIndex;
        }

        if (borrowState.index == 0) {
            // Initialize borrow state index with default value
            borrowState.index = arsInitialIndex;
        }

        /*
         * Update market state block numbers
         */
         supplyState.block = borrowState.block = blockNumber;
    }


    /**
      * @notice Set the given borrow caps for the given aToken markets. Borrowing that brings total borrows to or above borrow cap will revert.
      * @dev Admin or borrowCapGuardian function to set the borrow caps. A borrow cap of 0 corresponds to unlimited borrowing.
      * @param aTokens The addresses of the markets (tokens) to change the borrow caps for
      * @param newBorrowCaps The new borrow cap values in underlying to be set. A value of 0 corresponds to unlimited borrowing.
      */
    function _setMarketBorrowCaps(AToken[] calldata aTokens, uint[] calldata newBorrowCaps) external {
    	require(msg.sender == admin || msg.sender == borrowCapGuardian, "only admin or borrow cap guardian can set borrow caps"); 

        uint numMarkets = aTokens.length;
        uint numBorrowCaps = newBorrowCaps.length;

        require(numMarkets != 0 && numMarkets == numBorrowCaps, "invalid input");

        for(uint i = 0; i < numMarkets; i++) {
            borrowCaps[address(aTokens[i])] = newBorrowCaps[i];
            emit NewBorrowCap(aTokens[i], newBorrowCaps[i]);
        }
    }

    /**
     * @notice Admin function to change the Borrow Cap Guardian
     * @param newBorrowCapGuardian The address of the new Borrow Cap Guardian
     */
    function _setBorrowCapGuardian(address newBorrowCapGuardian) external {
        require(msg.sender == admin, "only admin can set borrow cap guardian");

        // Save current value for inclusion in log
        address oldBorrowCapGuardian = borrowCapGuardian;

        // Store borrowCapGuardian with value newBorrowCapGuardian
        borrowCapGuardian = newBorrowCapGuardian;

        // Emit NewBorrowCapGuardian(OldBorrowCapGuardian, NewBorrowCapGuardian)
        emit NewBorrowCapGuardian(oldBorrowCapGuardian, newBorrowCapGuardian);
    }

    /**
     * @notice Admin function to change the Pause Guardian
     * @param newPauseGuardian The address of the new Pause Guardian
     * @return uint 0=success, otherwise a failure. (See enum Error for details)
     */
    function _setPauseGuardian(address newPauseGuardian) public returns (uint) {
        if (msg.sender != admin) {
            return fail(Error.UNAUTHORIZED, FailureInfo.SET_PAUSE_GUARDIAN_OWNER_CHECK);
        }

        // Save current value for inclusion in log
        address oldPauseGuardian = pauseGuardian;

        // Store pauseGuardian with value newPauseGuardian
        pauseGuardian = newPauseGuardian;

        // Emit NewPauseGuardian(OldPauseGuardian, NewPauseGuardian)
        emit NewPauseGuardian(oldPauseGuardian, pauseGuardian);

        return uint(Error.NO_ERROR);
    }

    function _setMintPaused(AToken aToken, bool state) public returns (bool) {
        require(markets[address(aToken)].isListed, "cannot pause a market that is not listed");
        require(msg.sender == pauseGuardian || msg.sender == admin, "only pause guardian and admin can pause");
        require(msg.sender == admin || state == true, "only admin can unpause");

        mintGuardianPaused[address(aToken)] = state;
        emit ActionPaused(aToken, "Mint", state);
        return state;
    }

    function _setBorrowPaused(AToken aToken, bool state) public returns (bool) {
        require(markets[address(aToken)].isListed, "cannot pause a market that is not listed");
        require(msg.sender == pauseGuardian || msg.sender == admin, "only pause guardian and admin can pause");
        require(msg.sender == admin || state == true, "only admin can unpause");

        borrowGuardianPaused[address(aToken)] = state;
        emit ActionPaused(aToken, "Borrow", state);
        return state;
    }

    function _setTransferPaused(bool state) public returns (bool) {
        require(msg.sender == pauseGuardian || msg.sender == admin, "only pause guardian and admin can pause");
        require(msg.sender == admin || state == true, "only admin can unpause");

        transferGuardianPaused = state;
        emit ActionPaused("Transfer", state);
        return state;
    }

    function _setSeizePaused(bool state) public returns (bool) {
        require(msg.sender == pauseGuardian || msg.sender == admin, "only pause guardian and admin can pause");
        require(msg.sender == admin || state == true, "only admin can unpause");

        seizeGuardianPaused = state;
        emit ActionPaused("Seize", state);
        return state;
    }

    function _become(Unitroller unitroller) public {
        require(msg.sender == unitroller.admin(), "only unitroller admin can change brains");
        require(unitroller._acceptImplementation() == 0, "change not authorized");
    }

    /// @notice Delete this function after proposal 65 is executed
    function fixBadAccruals(address[] calldata affectedUsers, uint[] calldata amounts) external {
        require(msg.sender == admin, "Only admin can call this function"); // Only the timelock can call this function
        require(!proposal65FixExecuted, "Already executed this one-off function"); // Require that this function is only called once
        require(affectedUsers.length == amounts.length, "Invalid input");

        // Loop variables
        address user;
        uint currentAccrual;
        uint amountToSubtract;
        uint newAccrual;

        // Iterate through all affected users
        for (uint i = 0; i < affectedUsers.length; ++i) {
            user = affectedUsers[i];
            currentAccrual = arsAccrued[user];

            amountToSubtract = amounts[i];

            // The case where the user has claimed and received an incorrect amount of ARS.
            // The user has less currently accrued than the amount they incorrectly received.
            if (amountToSubtract > currentAccrual) {
                // Amount of ARS the user owes the protocol
                uint accountReceivable = amountToSubtract - currentAccrual; // Underflow safe since amountToSubtract > currentAccrual

                uint oldReceivable = arsReceivable[user];
                uint newReceivable = add_(oldReceivable, accountReceivable);

                // Accounting: record the ARS debt for the user
                arsReceivable[user] = newReceivable;

                emit ArsReceivableUpdated(user, oldReceivable, newReceivable);

                amountToSubtract = currentAccrual;
            }
            
            if (amountToSubtract > 0) {
                // Subtract the bad accrual amount from what they have accrued.
                // Users will keep whatever they have correctly accrued.
                arsAccrued[user] = newAccrual = sub_(currentAccrual, amountToSubtract);

                emit ArsAccruedAdjusted(user, currentAccrual, newAccrual);
            }
        }

        proposal65FixExecuted = true; // Makes it so that this function cannot be called again
    }

    /**
     * @notice Checks caller is admin, or this contract is becoming the new implementation
     */
    function adminOrInitializing() internal view returns (bool) {
        return msg.sender == admin || msg.sender == comptrollerImplementation;
    }

    /*** Ars Distribution ***/

    /**
     * @notice Set ARS speed for a single market
     * @param aToken The market whose ARS speed to update
     * @param supplySpeed New supply-side ARS speed for market
     * @param borrowSpeed New borrow-side ARS speed for market
     */
    function setArsSpeedInternal(AToken aToken, uint supplySpeed, uint borrowSpeed) internal {
        Market storage market = markets[address(aToken)];
        require(market.isListed, "ars market is not listed");

        if (arsSupplySpeeds[address(aToken)] != supplySpeed) {
            // Supply speed updated so let's update supply state to ensure that
            //  1. ARS accrued properly for the old speed, and
            //  2. ARS accrued at the new speed starts after this block.
            updateArsSupplyIndex(address(aToken));

            // Update speed and emit event
            arsSupplySpeeds[address(aToken)] = supplySpeed;
            emit ArsSupplySpeedUpdated(aToken, supplySpeed);
        }

        if (arsBorrowSpeeds[address(aToken)] != borrowSpeed) {
            // Borrow speed updated so let's update borrow state to ensure that
            //  1. ARS accrued properly for the old speed, and
            //  2. ARS accrued at the new speed starts after this block.
            Exp memory borrowIndex = Exp({mantissa: aToken.borrowIndex()});
            updateArsBorrowIndex(address(aToken), borrowIndex);

            // Update speed and emit event
            arsBorrowSpeeds[address(aToken)] = borrowSpeed;
            emit ArsBorrowSpeedUpdated(aToken, borrowSpeed);
        }
    }

    /**
     * @notice Accrue ARS to the market by updating the supply index
     * @param aToken The market whose supply index to update
     * @dev Index is a cumulative sum of the ARS per aToken accrued.
     */
    function updateArsSupplyIndex(address aToken) internal {
        ArsMarketState storage supplyState = arsSupplyState[aToken];
        uint supplySpeed = arsSupplySpeeds[aToken];
        uint32 blockNumber = safe32(getBlockNumber(), "block number exceeds 32 bits");
        uint deltaBlocks = sub_(uint(blockNumber), uint(supplyState.block));
        if (deltaBlocks > 0 && supplySpeed > 0) {
            uint supplyTokens = AToken(aToken).totalSupply();
            uint arsAccrued = mul_(deltaBlocks, supplySpeed);
            Double memory ratio = supplyTokens > 0 ? fraction(arsAccrued, supplyTokens) : Double({mantissa: 0});
            supplyState.index = safe224(add_(Double({mantissa: supplyState.index}), ratio).mantissa, "new index exceeds 224 bits");
            supplyState.block = blockNumber;
        } else if (deltaBlocks > 0) {
            supplyState.block = blockNumber;
        }
    }

    /**
     * @notice Accrue ARS to the market by updating the borrow index
     * @param aToken The market whose borrow index to update
     * @dev Index is a cumulative sum of the ARS per aToken accrued.
     */
    function updateArsBorrowIndex(address aToken, Exp memory marketBorrowIndex) internal {
        ArsMarketState storage borrowState = arsBorrowState[aToken];
        uint borrowSpeed = arsBorrowSpeeds[aToken];
        uint32 blockNumber = safe32(getBlockNumber(), "block number exceeds 32 bits");
        uint deltaBlocks = sub_(uint(blockNumber), uint(borrowState.block));
        if (deltaBlocks > 0 && borrowSpeed > 0) {
            uint borrowAmount = div_(AToken(aToken).totalBorrows(), marketBorrowIndex);
            uint arsAccrued = mul_(deltaBlocks, borrowSpeed);
            Double memory ratio = borrowAmount > 0 ? fraction(arsAccrued, borrowAmount) : Double({mantissa: 0});
            borrowState.index = safe224(add_(Double({mantissa: borrowState.index}), ratio).mantissa, "new index exceeds 224 bits");
            borrowState.block = blockNumber;
        } else if (deltaBlocks > 0) {
            borrowState.block = blockNumber;
        }
    }

    /**
     * @notice Calculate ARS accrued by a supplier and possibly transfer it to them
     * @param aToken The market in which the supplier is interacting
     * @param supplier The address of the supplier to distribute ARS to
     */
    function distributeSupplierArs(address aToken, address supplier) internal {
        // TODO: Don't distribute supplier ARS if the user is not in the supplier market.
        // This check should be as gas efficient as possible as distributeSupplierArs is called in many places.
        // - We really don't want to call an external contract as that's quite expensive.

        ArsMarketState storage supplyState = arsSupplyState[aToken];
        uint supplyIndex = supplyState.index;
        uint supplierIndex = arsSupplierIndex[aToken][supplier];

        // Update supplier's index to the current index since we are distributing accrued ARS
        arsSupplierIndex[aToken][supplier] = supplyIndex;

        if (supplierIndex == 0 && supplyIndex >= arsInitialIndex) {
            // Covers the case where users supplied tokens before the market's supply state index was set.
            // Rewards the user with ARS accrued from the start of when supplier rewards were first
            // set for the market.
            supplierIndex = arsInitialIndex;
        }

        // Calculate change in the cumulative sum of the ARS per aToken accrued
        Double memory deltaIndex = Double({mantissa: sub_(supplyIndex, supplierIndex)});

        uint supplierTokens = AToken(aToken).balanceOf(supplier);

        // Calculate ARS accrued: aTokenAmount * accruedPerAToken
        uint supplierDelta = mul_(supplierTokens, deltaIndex);

        uint supplierAccrued = add_(arsAccrued[supplier], supplierDelta);
        arsAccrued[supplier] = supplierAccrued;

        emit DistributedSupplierArs(AToken(aToken), supplier, supplierDelta, supplyIndex);
    }

    /**
     * @notice Calculate ARS accrued by a borrower and possibly transfer it to them
     * @dev Borrowers will not begin to accrue until after the first interaction with the protocol.
     * @param aToken The market in which the borrower is interacting
     * @param borrower The address of the borrower to distribute ARS to
     */
    function distributeBorrowerArs(address aToken, address borrower, Exp memory marketBorrowIndex) internal {
        // TODO: Don't distribute supplier ARS if the user is not in the borrower market.
        // This check should be as gas efficient as possible as distributeBorrowerArs is called in many places.
        // - We really don't want to call an external contract as that's quite expensive.

        ArsMarketState storage borrowState = arsBorrowState[aToken];
        uint borrowIndex = borrowState.index;
        uint borrowerIndex = arsBorrowerIndex[aToken][borrower];

        // Update borrowers's index to the current index since we are distributing accrued ARS
        arsBorrowerIndex[aToken][borrower] = borrowIndex;

        if (borrowerIndex == 0 && borrowIndex >= arsInitialIndex) {
            // Covers the case where users borrowed tokens before the market's borrow state index was set.
            // Rewards the user with ARS accrued from the start of when borrower rewards were first
            // set for the market.
            borrowerIndex = arsInitialIndex;
        }

        // Calculate change in the cumulative sum of the ARS per borrowed unit accrued
        Double memory deltaIndex = Double({mantissa: sub_(borrowIndex, borrowerIndex)});

        uint borrowerAmount = div_(AToken(aToken).borrowBalanceStored(borrower), marketBorrowIndex);
        
        // Calculate ARS accrued: aTokenAmount * accruedPerBorrowedUnit
        uint borrowerDelta = mul_(borrowerAmount, deltaIndex);

        uint borrowerAccrued = add_(arsAccrued[borrower], borrowerDelta);
        arsAccrued[borrower] = borrowerAccrued;

        emit DistributedBorrowerArs(AToken(aToken), borrower, borrowerDelta, borrowIndex);
    }

    /**
     * @notice Calculate additional accrued ARS for a contributor since last accrual
     * @param contributor The address to calculate contributor rewards for
     */
    function updateContributorRewards(address contributor) public {
        uint arsSpeed = arsContributorSpeeds[contributor];
        uint blockNumber = getBlockNumber();
        uint deltaBlocks = sub_(blockNumber, lastContributorBlock[contributor]);
        if (deltaBlocks > 0 && arsSpeed > 0) {
            uint newAccrued = mul_(deltaBlocks, arsSpeed);
            uint contributorAccrued = add_(arsAccrued[contributor], newAccrued);

            arsAccrued[contributor] = contributorAccrued;
            lastContributorBlock[contributor] = blockNumber;
        }
    }

    /**
     * @notice Claim all the ars accrued by holder in all markets
     * @param holder The address to claim ARS for
     */
    function claimArs(address holder) public {
        return claimArs(holder, allMarkets);
    }

    /**
     * @notice Claim all the ars accrued by holder in the specified markets
     * @param holder The address to claim ARS for
     * @param aTokens The list of markets to claim ARS in
     */
    function claimArs(address holder, AToken[] memory aTokens) public {
        address[] memory holders = new address[](1);
        holders[0] = holder;
        claimArs(holders, aTokens, true, true);
    }

    /**
     * @notice Claim all ars accrued by the holders
     * @param holders The addresses to claim ARS for
     * @param aTokens The list of markets to claim ARS in
     * @param borrowers Whether or not to claim ARS earned by borrowing
     * @param suppliers Whether or not to claim ARS earned by supplying
     */
    function claimArs(address[] memory holders, AToken[] memory aTokens, bool borrowers, bool suppliers) public {
        for (uint i = 0; i < aTokens.length; i++) {
            AToken aToken = aTokens[i];
            require(markets[address(aToken)].isListed, "market must be listed");
            if (borrowers == true) {
                Exp memory borrowIndex = Exp({mantissa: aToken.borrowIndex()});
                updateArsBorrowIndex(address(aToken), borrowIndex);
                for (uint j = 0; j < holders.length; j++) {
                    distributeBorrowerArs(address(aToken), holders[j], borrowIndex);
                }
            }
            if (suppliers == true) {
                updateArsSupplyIndex(address(aToken));
                for (uint j = 0; j < holders.length; j++) {
                    distributeSupplierArs(address(aToken), holders[j]);
                }
            }
        }
        for (uint j = 0; j < holders.length; j++) {
            arsAccrued[holders[j]] = grantArsInternal(holders[j], arsAccrued[holders[j]]);
        }
    }

    /**
     * @notice Transfer ARS to the user
     * @dev Note: If there is not enough ARS, we do not perform the transfer all.
     * @param user The address of the user to transfer ARS to
     * @param amount The amount of ARS to (possibly) transfer
     * @return The amount of ARS which was NOT transferred to the user
     */
    function grantArsInternal(address user, uint amount) internal returns (uint) {
        Ars ars = Ars(getArsAddress());
        uint arsRemaining = ars.balanceOf(address(this));
        if (amount > 0 && amount <= arsRemaining) {
            ars.transfer(user, amount);
            return 0;
        }
        return amount;
    }

    /*** Ars Distribution Admin ***/

    /**
     * @notice Transfer ARS to the recipient
     * @dev Note: If there is not enough ARS, we do not perform the transfer all.
     * @param recipient The address of the recipient to transfer ARS to
     * @param amount The amount of ARS to (possibly) transfer
     */
    function _grantArs(address recipient, uint amount) public {
        require(adminOrInitializing(), "only admin can grant ars");
        uint amountLeft = grantArsInternal(recipient, amount);
        require(amountLeft == 0, "insufficient ars for grant");
        emit ArsGranted(recipient, amount);
    }

    /**
     * @notice Set ARS borrow and supply speeds for the specified markets.
     * @param aTokens The markets whose ARS speed to update.
     * @param supplySpeeds New supply-side ARS speed for the corresponding market.
     * @param borrowSpeeds New borrow-side ARS speed for the corresponding market.
     */
    function _setArsSpeeds(AToken[] memory aTokens, uint[] memory supplySpeeds, uint[] memory borrowSpeeds) public {
        require(adminOrInitializing(), "only admin can set ars speed");

        uint numTokens = aTokens.length;
        require(numTokens == supplySpeeds.length && numTokens == borrowSpeeds.length, "Comptroller::_setArsSpeeds invalid input");

        for (uint i = 0; i < numTokens; ++i) {
            setArsSpeedInternal(aTokens[i], supplySpeeds[i], borrowSpeeds[i]);
        }
    }

    /**
     * @notice Set ARS speed for a single contributor
     * @param contributor The contributor whose ARS speed to update
     * @param arsSpeed New ARS speed for contributor
     */
    function _setContributorArsSpeed(address contributor, uint arsSpeed) public {
        require(adminOrInitializing(), "only admin can set ars speed");

        // note that ARS speed could be set to 0 to hars liquidity rewards for a contributor
        updateContributorRewards(contributor);
        if (arsSpeed == 0) {
            // release storage
            delete lastContributorBlock[contributor];
        } else {
            lastContributorBlock[contributor] = getBlockNumber();
        }
        arsContributorSpeeds[contributor] = arsSpeed;

        emit ContributorArsSpeedUpdated(contributor, arsSpeed);
    }

    /**
     * @notice Return all of the markets
     * @dev The automatic getter may be used to access an individual market.
     * @return The list of market addresses
     */
    function getAllMarkets() public view returns (AToken[] memory) {
        return allMarkets;
    }

    /**
     * @notice Returns true if the given aToken market has been deprecated
     * @dev All borrows in a deprecated aToken market can be immediately liquidated
     * @param aToken The market to check if deprecated
     */
    function isDeprecated(AToken aToken) public view returns (bool) {
        return
            markets[address(aToken)].collateralFactorMantissa == 0 && 
            borrowGuardianPaused[address(aToken)] == true && 
            aToken.reserveFactorMantissa() == 1e18
        ;
    }

    function getBlockNumber() public view returns (uint) {
        return block.number;
    }

    /**
     * @notice Return the address of the ARS token
     * @return The address of ARS
     */
    function getArsAddress() public view returns (address) {
        return 0x8f57E33C1f7f6e2886eBA9f83464e5b308D83202;
    }
}

Contract ABI

[{"inputs":[],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"action","type":"string"},{"indexed":false,"internalType":"bool","name":"pauseState","type":"bool"}],"name":"ActionPaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"contract AToken","name":"aToken","type":"address"},{"indexed":false,"internalType":"string","name":"action","type":"string"},{"indexed":false,"internalType":"bool","name":"pauseState","type":"bool"}],"name":"ActionPaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"oldArsAccrued","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newArsAccrued","type":"uint256"}],"name":"ArsAccruedAdjusted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"contract AToken","name":"aToken","type":"address"},{"indexed":false,"internalType":"uint256","name":"newSpeed","type":"uint256"}],"name":"ArsBorrowSpeedUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"recipient","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ArsGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"oldArsReceivable","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newArsReceivable","type":"uint256"}],"name":"ArsReceivableUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"contract AToken","name":"aToken","type":"address"},{"indexed":false,"internalType":"uint256","name":"newSpeed","type":"uint256"}],"name":"ArsSupplySpeedUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"contributor","type":"address"},{"indexed":false,"internalType":"uint256","name":"newSpeed","type":"uint256"}],"name":"ContributorArsSpeedUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"contract AToken","name":"aToken","type":"address"},{"indexed":true,"internalType":"address","name":"borrower","type":"address"},{"indexed":false,"internalType":"uint256","name":"arsDelta","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"arsBorrowIndex","type":"uint256"}],"name":"DistributedBorrowerArs","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"contract AToken","name":"aToken","type":"address"},{"indexed":true,"internalType":"address","name":"supplier","type":"address"},{"indexed":false,"internalType":"uint256","name":"arsDelta","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"arsSupplyIndex","type":"uint256"}],"name":"DistributedSupplierArs","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"error","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"info","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"detail","type":"uint256"}],"name":"Failure","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"contract AToken","name":"aToken","type":"address"},{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"MarketEntered","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"contract AToken","name":"aToken","type":"address"},{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"MarketExited","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"contract AToken","name":"aToken","type":"address"}],"name":"MarketListed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"contract AToken","name":"aToken","type":"address"},{"indexed":false,"internalType":"uint256","name":"newBorrowCap","type":"uint256"}],"name":"NewBorrowCap","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"oldBorrowCapGuardian","type":"address"},{"indexed":false,"internalType":"address","name":"newBorrowCapGuardian","type":"address"}],"name":"NewBorrowCapGuardian","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"oldCloseFactorMantissa","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newCloseFactorMantissa","type":"uint256"}],"name":"NewCloseFactor","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"contract AToken","name":"aToken","type":"address"},{"indexed":false,"internalType":"uint256","name":"oldCollateralFactorMantissa","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newCollateralFactorMantissa","type":"uint256"}],"name":"NewCollateralFactor","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"oldLiquidationIncentiveMantissa","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newLiquidationIncentiveMantissa","type":"uint256"}],"name":"NewLiquidationIncentive","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"oldPauseGuardian","type":"address"},{"indexed":false,"internalType":"address","name":"newPauseGuardian","type":"address"}],"name":"NewPauseGuardian","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"contract PriceOracle","name":"oldPriceOracle","type":"address"},{"indexed":false,"internalType":"contract PriceOracle","name":"newPriceOracle","type":"address"}],"name":"NewPriceOracle","type":"event"},{"constant":false,"inputs":[{"internalType":"contract Unitroller","name":"unitroller","type":"address"}],"name":"_become","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"_borrowGuardianPaused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"_grantArs","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"_mintGuardianPaused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"contract AToken[]","name":"aTokens","type":"address[]"},{"internalType":"uint256[]","name":"supplySpeeds","type":"uint256[]"},{"internalType":"uint256[]","name":"borrowSpeeds","type":"uint256[]"}],"name":"_setArsSpeeds","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"newBorrowCapGuardian","type":"address"}],"name":"_setBorrowCapGuardian","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"contract AToken","name":"aToken","type":"address"},{"internalType":"bool","name":"state","type":"bool"}],"name":"_setBorrowPaused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"uint256","name":"newCloseFactorMantissa","type":"uint256"}],"name":"_setCloseFactor","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"contract AToken","name":"aToken","type":"address"},{"internalType":"uint256","name":"newCollateralFactorMantissa","type":"uint256"}],"name":"_setCollateralFactor","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"contributor","type":"address"},{"internalType":"uint256","name":"arsSpeed","type":"uint256"}],"name":"_setContributorArsSpeed","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"uint256","name":"newLiquidationIncentiveMantissa","type":"uint256"}],"name":"_setLiquidationIncentive","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"contract AToken[]","name":"aTokens","type":"address[]"},{"internalType":"uint256[]","name":"newBorrowCaps","type":"uint256[]"}],"name":"_setMarketBorrowCaps","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"contract AToken","name":"aToken","type":"address"},{"internalType":"bool","name":"state","type":"bool"}],"name":"_setMintPaused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"newPauseGuardian","type":"address"}],"name":"_setPauseGuardian","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"contract PriceOracle","name":"newOracle","type":"address"}],"name":"_setPriceOracle","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"bool","name":"state","type":"bool"}],"name":"_setSeizePaused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"bool","name":"state","type":"bool"}],"name":"_setTransferPaused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"contract AToken","name":"aToken","type":"address"}],"name":"_supportMarket","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"accountAssets","outputs":[{"internalType":"contract AToken","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"admin","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"allMarkets","outputs":[{"internalType":"contract AToken","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"arsAccrued","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"arsBorrowSpeeds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"arsBorrowState","outputs":[{"internalType":"uint224","name":"index","type":"uint224"},{"internalType":"uint32","name":"block","type":"uint32"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"}],"name":"arsBorrowerIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"arsContributorSpeeds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"arsInitialIndex","outputs":[{"internalType":"uint224","name":"","type":"uint224"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"arsRate","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"arsReceivable","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"arsSpeeds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"}],"name":"arsSupplierIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"arsSupplySpeeds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"arsSupplyState","outputs":[{"internalType":"uint224","name":"index","type":"uint224"},{"internalType":"uint32","name":"block","type":"uint32"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"aToken","type":"address"},{"internalType":"address","name":"borrower","type":"address"},{"internalType":"uint256","name":"borrowAmount","type":"uint256"}],"name":"borrowAllowed","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"borrowCapGuardian","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"borrowCaps","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"borrowGuardianPaused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"aToken","type":"address"},{"internalType":"address","name":"borrower","type":"address"},{"internalType":"uint256","name":"borrowAmount","type":"uint256"}],"name":"borrowVerify","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"contract AToken","name":"aToken","type":"address"}],"name":"checkMembership","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"holder","type":"address"}],"name":"claimArs","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"holder","type":"address"},{"internalType":"contract AToken[]","name":"aTokens","type":"address[]"}],"name":"claimArs","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address[]","name":"holders","type":"address[]"},{"internalType":"contract AToken[]","name":"aTokens","type":"address[]"},{"internalType":"bool","name":"borrowers","type":"bool"},{"internalType":"bool","name":"suppliers","type":"bool"}],"name":"claimArs","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"closeFactorMantissa","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"comptrollerImplementation","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address[]","name":"aTokens","type":"address[]"}],"name":"enterMarkets","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"aTokenAddress","type":"address"}],"name":"exitMarket","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address[]","name":"affectedUsers","type":"address[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"fixBadAccruals","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"getAccountLiquidity","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"getAllMarkets","outputs":[{"internalType":"contract AToken[]","name":"","type":"address[]"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"getArsAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"getAssetsIn","outputs":[{"internalType":"contract AToken[]","name":"","type":"address[]"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"getBlockNumber","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"address","name":"aTokenModify","type":"address"},{"internalType":"uint256","name":"redeemTokens","type":"uint256"},{"internalType":"uint256","name":"borrowAmount","type":"uint256"}],"name":"getHypotheticalAccountLiquidity","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"isComptroller","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"contract AToken","name":"aToken","type":"address"}],"name":"isDeprecated","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"lastContributorBlock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"aTokenBorrowed","type":"address"},{"internalType":"address","name":"aTokenCollateral","type":"address"},{"internalType":"address","name":"liquidator","type":"address"},{"internalType":"address","name":"borrower","type":"address"},{"internalType":"uint256","name":"repayAmount","type":"uint256"}],"name":"liquidateBorrowAllowed","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"aTokenBorrowed","type":"address"},{"internalType":"address","name":"aTokenCollateral","type":"address"},{"internalType":"address","name":"liquidator","type":"address"},{"internalType":"address","name":"borrower","type":"address"},{"internalType":"uint256","name":"actualRepayAmount","type":"uint256"},{"internalType":"uint256","name":"seizeTokens","type":"uint256"}],"name":"liquidateBorrowVerify","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"aTokenBorrowed","type":"address"},{"internalType":"address","name":"aTokenCollateral","type":"address"},{"internalType":"uint256","name":"actualRepayAmount","type":"uint256"}],"name":"liquidateCalculateSeizeTokens","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"liquidationIncentiveMantissa","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"markets","outputs":[{"internalType":"bool","name":"isListed","type":"bool"},{"internalType":"uint256","name":"collateralFactorMantissa","type":"uint256"},{"internalType":"bool","name":"isComped","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"maxAssets","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"aToken","type":"address"},{"internalType":"address","name":"minter","type":"address"},{"internalType":"uint256","name":"mintAmount","type":"uint256"}],"name":"mintAllowed","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"mintGuardianPaused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"aToken","type":"address"},{"internalType":"address","name":"minter","type":"address"},{"internalType":"uint256","name":"actualMintAmount","type":"uint256"},{"internalType":"uint256","name":"mintTokens","type":"uint256"}],"name":"mintVerify","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"oracle","outputs":[{"internalType":"contract PriceOracle","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"pauseGuardian","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"pendingAdmin","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"pendingComptrollerImplementation","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"proposal65FixExecuted","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"aToken","type":"address"},{"internalType":"address","name":"redeemer","type":"address"},{"internalType":"uint256","name":"redeemTokens","type":"uint256"}],"name":"redeemAllowed","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"aToken","type":"address"},{"internalType":"address","name":"redeemer","type":"address"},{"internalType":"uint256","name":"redeemAmount","type":"uint256"},{"internalType":"uint256","name":"redeemTokens","type":"uint256"}],"name":"redeemVerify","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"aToken","type":"address"},{"internalType":"address","name":"payer","type":"address"},{"internalType":"address","name":"borrower","type":"address"},{"internalType":"uint256","name":"repayAmount","type":"uint256"}],"name":"repayBorrowAllowed","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"aToken","type":"address"},{"internalType":"address","name":"payer","type":"address"},{"internalType":"address","name":"borrower","type":"address"},{"internalType":"uint256","name":"actualRepayAmount","type":"uint256"},{"internalType":"uint256","name":"borrowerIndex","type":"uint256"}],"name":"repayBorrowVerify","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"aTokenCollateral","type":"address"},{"internalType":"address","name":"aTokenBorrowed","type":"address"},{"internalType":"address","name":"liquidator","type":"address"},{"internalType":"address","name":"borrower","type":"address"},{"internalType":"uint256","name":"seizeTokens","type":"uint256"}],"name":"seizeAllowed","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"seizeGuardianPaused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"aTokenCollateral","type":"address"},{"internalType":"address","name":"aTokenBorrowed","type":"address"},{"internalType":"address","name":"liquidator","type":"address"},{"internalType":"address","name":"borrower","type":"address"},{"internalType":"uint256","name":"seizeTokens","type":"uint256"}],"name":"seizeVerify","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"aToken","type":"address"},{"internalType":"address","name":"src","type":"address"},{"internalType":"address","name":"dst","type":"address"},{"internalType":"uint256","name":"transferTokens","type":"uint256"}],"name":"transferAllowed","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"transferGuardianPaused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"aToken","type":"address"},{"internalType":"address","name":"src","type":"address"},{"internalType":"address","name":"dst","type":"address"},{"internalType":"uint256","name":"transferTokens","type":"uint256"}],"name":"transferVerify","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"contributor","type":"address"}],"name":"updateContributorRewards","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"}]

608060405234801561001057600080fd5b50600080546001600160a01b03191633179055615b2a80620000336000396000f3fe608060405234801561001057600080fd5b506004361061048a5760003560e01c8063731f0c2b11610262578063bea6b8b811610151578063e4028eee116100ce578063ec1b16de11610092578063ec1b16de146113ea578063ede4edd014611410578063f00a7a9214611436578063f851a4401461143e578063fa47f47d14611446578063fe815df71461146c5761048a565b8063e4028eee1461134a578063e5037f1414611376578063e6653f3d146113a4578063e8755446146113ac578063eabe7d91146113b45761048a565b8063d02f735111610115578063d02f7351146110f5578063da3d454c1461113b578063dce1544914611171578063dcfbc0c71461119d578063e3404c8a146111a55761048a565b8063bea6b8b814610f85578063bf15912314610fab578063c299823814610fd7578063c488847b14611078578063c63fdc4b146110c75761048a565b806394d3001f116101df578063abfceffc116101a3578063abfceffc14610ebb578063ac0b0bb714610f31578063b0772d0b14610f39578063bb82aa5e14610f41578063bdcdc25814610f495761048a565b806394d3001f14610e155780639d10433d14610e415780639e1fce0b14610e67578063a76b3fda14610e6f578063a9d9a97114610e955761048a565b80638e8f294b116102265780638e8f294b14610d525780638ebf636414610d9a578063929fe9a114610db957806394543c1514610de757806394b2294b14610e0d5761048a565b8063731f0c2b14610cee578063741b252514610d14578063768e3dc414610d3a5780637dc0d1d014610d4257806387f7630314610d4a5761048a565b806341c728b91161037e57806355ee1fe1116102fb578063607ef6c1116102bf578063607ef6c114610b625780636919de6314610c205780636a56947e14610c465780636d154ea514610c825780636d35bf9114610ca85761048a565b806355ee1fe114610a745780635c77860514610a9a5780635ec88c7914610ad05780635f5af1aa14610af65780635fc7e71e14610b1c5761048a565b80634e79238f116103425780634e79238f1461096e5780634ef4c3e1146109c85780634fd42e17146109fe57806351dff98914610a1b57806352d84d1e14610a575761048a565b806341c728b9146108b057806342cbb15c146108ec57806347ef3b3b146108f45780634a584432146109405780634ada90af146109665761048a565b806324008a621161040c578063317b0b77116103d0578063317b0b7714610811578063391957d71461082e5780633bcf7ec1146108545780633c94786f146108825780633e2d72111461088a5761048a565b806324008a621461075857806324a3d62214610794578063267822471461079c5780632d70db78146107a45780632f040ee8146107c35761048a565b806318c882a51161045357806318c882a5146105ed5780631d504dc61461061b5780631ededc911461064157806321af45691461068357806322f81391146106a75761048a565b80627e3dd21461048f57806302147658146104ab5780631125d627146104cf57806316b95e8f1461050757806317efa2c2146105c7575b600080fd5b610497611598565b604080519115158252519081900360200190f35b6104b361159d565b604080516001600160e01b039092168252519081900360200190f35b6104f5600480360360208110156104e557600080fd5b50356001600160a01b03166115af565b60408051918252519081900360200190f35b6105c56004803603604081101561051d57600080fd5b810190602081018135600160201b81111561053757600080fd5b82018360208201111561054957600080fd5b803590602001918460208302840111600160201b8311171561056a57600080fd5b919390929091602081019035600160201b81111561058757600080fd5b82018360208201111561059957600080fd5b803590602001918460208302840111600160201b831117156105ba57600080fd5b5090925090506115c1565b005b6105c5600480360360208110156105dd57600080fd5b50356001600160a01b0316611817565b6104976004803603604081101561060357600080fd5b506001600160a01b038135169060200135151561187e565b6105c56004803603602081101561063157600080fd5b50356001600160a01b0316611a1e565b6105c5600480360360a081101561065757600080fd5b506001600160a01b03813581169160208101358216916040820135169060608101359060800135611b7a565b61068b611b81565b604080516001600160a01b039092168252519081900360200190f35b6105c5600480360360408110156106bd57600080fd5b6001600160a01b038235169190810190604081016020820135600160201b8111156106e757600080fd5b8201836020820111156106f957600080fd5b803590602001918460208302840111600160201b8311171561071a57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550611b90945050505050565b6104f56004803603608081101561076e57600080fd5b506001600160a01b03813581169160208101358216916040820135169060600135611bf2565b61068b611cb9565b61068b611cc8565b610497600480360360208110156107ba57600080fd5b50351515611cd7565b6107e9600480360360208110156107d957600080fd5b50356001600160a01b0316611e11565b604080516001600160e01b03909316835263ffffffff90911660208301528051918290030190f35b6104f56004803603602081101561082757600080fd5b5035611e3b565b6105c56004803603602081101561084457600080fd5b50356001600160a01b0316611ee8565b6104976004803603604081101561086a57600080fd5b506001600160a01b0381351690602001351515611f94565b61049761212f565b6104f5600480360360208110156108a057600080fd5b50356001600160a01b031661213f565b6105c5600480360360808110156108c657600080fd5b506001600160a01b03813581169160208101359091169060408101359060600135612151565b6104f5612157565b6105c5600480360360c081101561090a57600080fd5b506001600160a01b0381358116916020810135821691604082013581169160608101359091169060808101359060a0013561215c565b6104f56004803603602081101561095657600080fd5b50356001600160a01b0316612164565b6104f5612176565b6109aa6004803603608081101561098457600080fd5b506001600160a01b0381358116916020810135909116906040810135906060013561217c565b60408051938452602084019290925282820152519081900360600190f35b6104f5600480360360608110156109de57600080fd5b506001600160a01b038135811691602081013590911690604001356121b6565b6104f560048036036020811015610a1457600080fd5b503561225c565b6105c560048036036080811015610a3157600080fd5b506001600160a01b038135811691602081013590911690604081013590606001356122cc565b61068b60048036036020811015610a6d57600080fd5b5035612320565b6104f560048036036020811015610a8a57600080fd5b50356001600160a01b0316612347565b6105c560048036036060811015610ab057600080fd5b506001600160a01b038135811691602081013590911690604001356123cc565b6109aa60048036036020811015610ae657600080fd5b50356001600160a01b03166123d1565b6104f560048036036020811015610b0c57600080fd5b50356001600160a01b0316612406565b6104f5600480360360a0811015610b3257600080fd5b506001600160a01b038135811691602081013582169160408201358116916060810135909116906080013561248a565b6105c560048036036040811015610b7857600080fd5b810190602081018135600160201b811115610b9257600080fd5b820183602082011115610ba457600080fd5b803590602001918460208302840111600160201b83111715610bc557600080fd5b919390929091602081019035600160201b811115610be257600080fd5b820183602082011115610bf457600080fd5b803590602001918460208302840111600160201b83111715610c1557600080fd5b509092509050612641565b6104f560048036036020811015610c3657600080fd5b50356001600160a01b03166127d1565b6105c560048036036080811015610c5c57600080fd5b506001600160a01b03813581169160208101358216916040820135169060600135612151565b61049760048036036020811015610c9857600080fd5b50356001600160a01b03166127e3565b6105c5600480360360a0811015610cbe57600080fd5b506001600160a01b0381358116916020810135821691604082013581169160608101359091169060800135611b7a565b61049760048036036020811015610d0457600080fd5b50356001600160a01b03166127f8565b6105c560048036036020811015610d2a57600080fd5b50356001600160a01b031661280d565b6104f56128d0565b61068b6128d6565b6104976128e5565b610d7860048036036020811015610d6857600080fd5b50356001600160a01b03166128f5565b6040805193151584526020840192909252151582820152519081900360600190f35b61049760048036036020811015610db057600080fd5b5035151561291b565b61049760048036036040811015610dcf57600080fd5b506001600160a01b0381358116916020013516612a54565b61049760048036036020811015610dfd57600080fd5b50356001600160a01b0316612a87565b6104f5612b49565b6105c560048036036040811015610e2b57600080fd5b506001600160a01b038135169060200135612b4f565b6104f560048036036020811015610e5757600080fd5b50356001600160a01b0316612c4a565b61068b612c5c565b6104f560048036036020811015610e8557600080fd5b50356001600160a01b0316612c74565b6107e960048036036020811015610eab57600080fd5b50356001600160a01b0316612dd9565b610ee160048036036020811015610ed157600080fd5b50356001600160a01b0316612e03565b60408051602080825283518183015283519192839290830191858101910280838360005b83811015610f1d578181015183820152602001610f05565b505050509050019250505060405180910390f35b610497612e8c565b610ee1612e9c565b61068b612efe565b6104f560048036036080811015610f5f57600080fd5b506001600160a01b03813581169160208101358216916040820135169060600135612f0d565b6104f560048036036020811015610f9b57600080fd5b50356001600160a01b0316612f9d565b6105c560048036036040811015610fc157600080fd5b506001600160a01b038135169060200135612faf565b610ee160048036036020811015610fed57600080fd5b810190602081018135600160201b81111561100757600080fd5b82018360208201111561101957600080fd5b803590602001918460208302840111600160201b8311171561103a57600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295506130b2945050505050565b6110ae6004803603606081101561108e57600080fd5b506001600160a01b03813581169160208101359091169060400135613149565b6040805192835260208301919091528051918290030190f35b6104f5600480360360408110156110dd57600080fd5b506001600160a01b0381358116916020013516613371565b6104f5600480360360a081101561110b57600080fd5b506001600160a01b038135811691602081013582169160408201358116916060810135909116906080013561338e565b6104f56004803603606081101561115157600080fd5b506001600160a01b03813581169160208101359091169060400135613542565b61068b6004803603604081101561118757600080fd5b506001600160a01b03813516906020013561391c565b61068b613951565b6105c5600480360360608110156111bb57600080fd5b810190602081018135600160201b8111156111d557600080fd5b8201836020820111156111e757600080fd5b803590602001918460208302840111600160201b8311171561120857600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295949360208101935035915050600160201b81111561125757600080fd5b82018360208201111561126957600080fd5b803590602001918460208302840111600160201b8311171561128a57600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295949360208101935035915050600160201b8111156112d957600080fd5b8201836020820111156112eb57600080fd5b803590602001918460208302840111600160201b8311171561130c57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550613960945050505050565b6104f56004803603604081101561136057600080fd5b506001600160a01b038135169060200135613a5d565b6104f56004803603604081101561138c57600080fd5b506001600160a01b0381358116916020013516613c0d565b610497613c2a565b6104f5613c3a565b6104f5600480360360608110156113ca57600080fd5b506001600160a01b03813581169160208101359091169060400135613c40565b6104f56004803603602081101561140057600080fd5b50356001600160a01b0316613c7b565b6104f56004803603602081101561142657600080fd5b50356001600160a01b0316613c8d565b610497613fa0565b61068b613fa9565b6104f56004803603602081101561145c57600080fd5b50356001600160a01b0316613fb8565b6105c56004803603608081101561148257600080fd5b810190602081018135600160201b81111561149c57600080fd5b8201836020820111156114ae57600080fd5b803590602001918460208302840111600160201b831117156114cf57600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295949360208101935035915050600160201b81111561151e57600080fd5b82018360208201111561153057600080fd5b803590602001918460208302840111600160201b8311171561155157600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550505050803515159150602001351515613fca565b600181565b6a0c097ce7bc90715b34b9f160241b81565b60176020526000908152604090205481565b6000546001600160a01b0316331461160a5760405162461bcd60e51b8152600401808060200182810382526021815260200180615aae6021913960400191505060405180910390fd5b601b5460ff161561164c5760405162461bcd60e51b81526004018080602001828103825260268152602001806159b96026913960400191505060405180910390fd5b828114611690576040805162461bcd60e51b815260206004820152600d60248201526c125b9d985b1a59081a5b9c1d5d609a1b604482015290519081900360640190fd5b6000808080805b878110156117ff578888828181106116ab57fe5b905060200201356001600160a01b0316945060146000866001600160a01b03166001600160a01b031681526020019081526020016000205493508686828181106116f157fe5b9050602002013592508383111561178b576001600160a01b0385166000908152601c602052604081205485850391611729828461420d565b6001600160a01b0389166000818152601c60209081526040918290208490558151868152908101849052815193945091927f66fef805789c572d318945f327c22008b0f90ffeba0980b1404981695df3c4f89281900390910190a28695505050505b82156117f75761179b8484614243565b6001600160a01b0386166000818152601460209081526040918290208490558151888152908101849052815193955091927f24fad61822f6b333328e372b501c762eca75f16cd45e1f2c7a916ebece34a35c9281900390910190a25b600101611697565b5050601b805460ff1916600117905550505050505050565b61187b81600d80548060200260200160405190810160405280929190818152602001828054801561187157602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311611853575b5050505050611b90565b50565b6001600160a01b03821660009081526009602052604081205460ff166118d55760405162461bcd60e51b81526004018080602001828103825260288152602001806159696028913960400191505060405180910390fd5b600a546001600160a01b03163314806118f857506000546001600160a01b031633145b6119335760405162461bcd60e51b81526004018080602001828103825260278152602001806159df6027913960400191505060405180910390fd5b6000546001600160a01b031633148061194e57506001821515145b611998576040805162461bcd60e51b81526020600482015260166024820152756f6e6c792061646d696e2063616e20756e706175736560501b604482015290519081900360640190fd5b6001600160a01b0383166000818152600c6020908152604091829020805486151560ff199091168117909155825193845283830152606090830181905260069083015265426f72726f7760d01b6080830152517f71aec636243f9709bb0007ae15e9afb8150ab01716d75fd7573be5cc096e03b09181900360a00190a150805b92915050565b806001600160a01b031663f851a4406040518163ffffffff1660e01b815260040160206040518083038186803b158015611a5757600080fd5b505afa158015611a6b573d6000803e3d6000fd5b505050506040513d6020811015611a8157600080fd5b50516001600160a01b03163314611ac95760405162461bcd60e51b8152600401808060200182810382526027815260200180615acf6027913960400191505060405180910390fd5b806001600160a01b031663c1e803346040518163ffffffff1660e01b8152600401602060405180830381600087803b158015611b0457600080fd5b505af1158015611b18573d6000803e3d6000fd5b505050506040513d6020811015611b2e57600080fd5b50511561187b576040805162461bcd60e51b815260206004820152601560248201527418da185b99d9481b9bdd08185d5d1a1bdc9a5e9959605a1b604482015290519081900360640190fd5b5050505050565b6015546001600160a01b031681565b604080516001808252818301909252606091602080830190803883390190505090508281600081518110611bc057fe5b60200260200101906001600160a01b031690816001600160a01b031681525050611bed8183600180613fca565b505050565b6001600160a01b03841660009081526009602052604081205460ff16611c1a57506009611cb1565b611c226158a9565b6040518060200160405280876001600160a01b031663aa5af0fd6040518163ffffffff1660e01b815260040160206040518083038186803b158015611c6657600080fd5b505afa158015611c7a573d6000803e3d6000fd5b505050506040513d6020811015611c9057600080fd5b505190529050611ca0868261427d565b611cab868583614490565b60009150505b949350505050565b600a546001600160a01b031681565b6001546001600160a01b031681565b600a546000906001600160a01b0316331480611cfd57506000546001600160a01b031633145b611d385760405162461bcd60e51b81526004018080602001828103825260278152602001806159df6027913960400191505060405180910390fd5b6000546001600160a01b0316331480611d5357506001821515145b611d9d576040805162461bcd60e51b81526020600482015260166024820152756f6e6c792061646d696e2063616e20756e706175736560501b604482015290519081900360640190fd5b600a8054831515600160b81b810260ff60b81b1990921691909117909155604080516020810192909252808252600582820152645365697a6560d81b6060830152517fef159d9a32b2472e32b098f954f3ce62d232939f1c207070b584df1814de2de09181900360800190a150805b919050565b6010602052600090815260409020546001600160e01b03811690600160e01b900463ffffffff1682565b600080546001600160a01b03163314611e9b576040805162461bcd60e51b815260206004820152601f60248201527f6f6e6c792061646d696e2063616e2073657420636c6f736520666163746f7200604482015290519081900360640190fd5b6005805490839055604080518281526020810185905281517f3b9670cf975d26958e754b57098eaa2ac914d8d2a31b83257997b9f346110fd9929181900390910190a160005b9392505050565b6000546001600160a01b03163314611f315760405162461bcd60e51b8152600401808060200182810382526026815260200180615a066026913960400191505060405180910390fd5b601580546001600160a01b038381166001600160a01b0319831681179093556040805191909216808252602082019390935281517feda98690e518e9a05f8ec6837663e188211b2da8f4906648b323f2c1d4434e29929181900390910190a15050565b6001600160a01b03821660009081526009602052604081205460ff16611feb5760405162461bcd60e51b81526004018080602001828103825260288152602001806159696028913960400191505060405180910390fd5b600a546001600160a01b031633148061200e57506000546001600160a01b031633145b6120495760405162461bcd60e51b81526004018080602001828103825260278152602001806159df6027913960400191505060405180910390fd5b6000546001600160a01b031633148061206457506001821515145b6120ae576040805162461bcd60e51b81526020600482015260166024820152756f6e6c792061646d696e2063616e20756e706175736560501b604482015290519081900360640190fd5b6001600160a01b0383166000818152600b6020908152604091829020805486151560ff199091168117909155825193845283830152606090830181905260049083015263135a5b9d60e21b6080830152517f71aec636243f9709bb0007ae15e9afb8150ab01716d75fd7573be5cc096e03b09181900360a00190a150919050565b600a54600160a01b900460ff1681565b600f6020526000908152604090205481565b50505050565b435b90565b505050505050565b60166020526000908152604090205481565b60065481565b6000806000806000806121918a8a8a8a614624565b9250925092508260118111156121a357fe5b95509093509150505b9450945094915050565b6001600160a01b0383166000908152600b602052604081205460ff1615612215576040805162461bcd60e51b815260206004820152600e60248201526d1b5a5b9d081a5cc81c185d5cd95960921b604482015290519081900360640190fd5b6001600160a01b03841660009081526009602052604090205460ff1661223f5760095b9050611ee1565b6122488461495c565b6122528484614af0565b6000949350505050565b600080546001600160a01b031633146122825761227b6001600b614cac565b9050611e0c565b6006805490839055604080518281526020810185905281517faeba5a6c40a8ac138134bff1aaa65debf25971188a58804bad717f82f0ec1316929181900390910190a16000611ee1565b801580156122da5750600082115b15612151576040805162461bcd60e51b815260206004820152601160248201527072656465656d546f6b656e73207a65726f60781b604482015290519081900360640190fd5b600d818154811061232d57fe5b6000918252602090912001546001600160a01b0316905081565b600080546001600160a01b031633146123665761227b60016010614cac565b600480546001600160a01b038481166001600160a01b0319831681179093556040805191909216808252602082019390935281517fd52b2b9b7e9ee655fcb95d2e5b9e0c9f69e7ef2b8e9d2d0ea78402d576d22e22929181900390910190a16000611ee1565b611bed565b6000806000806000806123e8876000806000614624565b9250925092508260118111156123fa57fe5b97919650945092505050565b600080546001600160a01b031633146124255761227b60016013614cac565b600a80546001600160a01b038481166001600160a01b0319831617928390556040805192821680845293909116602083015280517f0613b6ee6a04f0d09f390e4d9318894b9f6ac7fd83897cd8d18896ba579c401e9281900390910190a16000611ee1565b6001600160a01b03851660009081526009602052604081205460ff1615806124cb57506001600160a01b03851660009081526009602052604090205460ff16155b156124da5760095b9050612638565b6000866001600160a01b03166395dd9193856040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561253257600080fd5b505afa158015612546573d6000803e3d6000fd5b505050506040513d602081101561255c57600080fd5b5051905061256987612a87565b156125b257828110156125ad5760405162461bcd60e51b81526004018080602001828103825260288152602001806159916028913960400191505060405180910390fd5b612632565b6000806125be86614d12565b919350909150600090508260118111156125d457fe5b146125ef578160118111156125e557fe5b9350505050612638565b806125fb5760036125e5565b6000612617604051806020016040528060055481525085614d32565b90508086111561262e576011945050505050612638565b5050505b60009150505b95945050505050565b6000546001600160a01b031633148061266457506015546001600160a01b031633145b61269f5760405162461bcd60e51b8152600401808060200182810382526035815260200180615a546035913960400191505060405180910390fd5b828181158015906126af57508082145b6126f0576040805162461bcd60e51b815260206004820152600d60248201526c1a5b9d985b1a59081a5b9c1d5d609a1b604482015290519081900360640190fd5b60005b828110156127c85784848281811061270757fe5b905060200201356016600089898581811061271e57fe5b905060200201356001600160a01b03166001600160a01b03166001600160a01b031681526020019081526020016000208190555086868281811061275e57fe5b905060200201356001600160a01b03166001600160a01b03167f6f1951b2aad10f3fc81b86d91105b413a5b3f847a34bbc5ce1904201b14438f68686848181106127a457fe5b905060200201356040518082815260200191505060405180910390a26001016126f3565b50505050505050565b60196020526000908152604090205481565b600c6020526000908152604090205460ff1681565b600b6020526000908152604090205460ff1681565b6001600160a01b0381166000908152601760205260408120549061282f612157565b6001600160a01b03841660009081526018602052604081205491925090612857908390614243565b90506000811180156128695750600083115b1561215157600061287a8285614d51565b6001600160a01b038616600090815260146020526040812054919250906128a1908361420d565b6001600160a01b0387166000908152601460209081526040808320939093556018905220849055505050505050565b600e5481565b6004546001600160a01b031681565b600a54600160b01b900460ff1681565b60096020526000908152604090208054600182015460039092015460ff91821692911683565b600a546000906001600160a01b031633148061294157506000546001600160a01b031633145b61297c5760405162461bcd60e51b81526004018080602001828103825260278152602001806159df6027913960400191505060405180910390fd5b6000546001600160a01b031633148061299757506001821515145b6129e1576040805162461bcd60e51b81526020600482015260166024820152756f6e6c792061646d696e2063616e20756e706175736560501b604482015290519081900360640190fd5b600a8054831515600160b01b810260ff60b01b1990921691909117909155604080516020810192909252808252600882820152672a3930b739b332b960c11b6060830152517fef159d9a32b2472e32b098f954f3ce62d232939f1c207070b584df1814de2de09181900360800190a15090565b6001600160a01b038082166000908152600960209081526040808320938616835260029093019052205460ff1692915050565b6001600160a01b038116600090815260096020526040812060010154158015612acd57506001600160a01b0382166000908152600c602052604090205460ff1615156001145b8015611a185750816001600160a01b031663173b99046040518163ffffffff1660e01b815260040160206040518083038186803b158015612b0d57600080fd5b505afa158015612b21573d6000803e3d6000fd5b505050506040513d6020811015612b3757600080fd5b5051670de0b6b3a76400001492915050565b60075481565b612b57614d93565b612ba8576040805162461bcd60e51b815260206004820152601c60248201527f6f6e6c792061646d696e2063616e207365742061727320737065656400000000604482015290519081900360640190fd5b612bb18261280d565b80612bd4576001600160a01b038216600090815260186020526040812055612bf6565b612bdc612157565b6001600160a01b0383166000908152601860205260409020555b6001600160a01b038216600081815260176020908152604091829020849055815184815291517fad131fb09698eb20902388c161c2ca51da25735b495ea264868527e6cb196cb39281900390910190a25050565b601a6020526000908152604090205481565b738f57e33c1f7f6e2886eba9f83464e5b308d8320290565b600080546001600160a01b03163314612c935761227b60016012614cac565b6001600160a01b03821660009081526009602052604090205460ff1615612cc05761227b600a6011614cac565b816001600160a01b03166394c393fc6040518163ffffffff1660e01b815260040160206040518083038186803b158015612cf957600080fd5b505afa158015612d0d573d6000803e3d6000fd5b505050506040513d6020811015612d2357600080fd5b5050604080516060810182526001808252600060208381018281528486018381526001600160a01b03891684526009909252949091209251835490151560ff19918216178455935191830191909155516003909101805491151591909216179055612d8d82614dbc565b612d9682614e9a565b604080516001600160a01b038416815290517fcf583bb0c569eb967f806b11601c4cb93c10310485c67add5f8362c2f212321f9181900360200190a16000611a18565b6011602052600090815260409020546001600160e01b03811690600160e01b900463ffffffff1682565b60608060086000846001600160a01b03166001600160a01b03168152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015612e7f57602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311612e61575b5093979650505050505050565b600a54600160b81b900460ff1681565b6060600d805480602002602001604051908101604052809291908181526020018280548015612ef457602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311612ed6575b5050505050905090565b6002546001600160a01b031681565b600a54600090600160b01b900460ff1615612f64576040805162461bcd60e51b81526020600482015260126024820152711d1c985b9cd9995c881a5cc81c185d5cd95960721b604482015290519081900360640190fd5b6000612f71868685614f58565b90508015612f80579050611cb1565b612f898661495c565b612f938686614af0565b611cab8685614af0565b60186020526000908152604090205481565b612fb7614d93565b613008576040805162461bcd60e51b815260206004820152601860248201527f6f6e6c792061646d696e2063616e206772616e74206172730000000000000000604482015290519081900360640190fd5b60006130148383615004565b90508015613069576040805162461bcd60e51b815260206004820152601a60248201527f696e73756666696369656e742061727320666f72206772616e74000000000000604482015290519081900360640190fd5b604080516001600160a01b03851681526020810184905281517f0d9d61be0ce93f1896e1ca6ca63618fabc5e7ae514a306e75a21b521e8fb0b22929181900390910190a1505050565b60606000825190506060816040519080825280602002602001820160405280156130e6578160200160208202803883390190505b50905060005b8281101561314157600085828151811061310257fe5b60200260200101519050613116813361513e565b601181111561312157fe5b83838151811061312d57fe5b6020908102919091010152506001016130ec565b509392505050565b600480546040805163fc57d4df60e01b81526001600160a01b038781169482019490945290516000938493849391169163fc57d4df91602480820192602092909190829003018186803b15801561319f57600080fd5b505afa1580156131b3573d6000803e3d6000fd5b505050506040513d60208110156131c957600080fd5b5051600480546040805163fc57d4df60e01b81526001600160a01b038a8116948201949094529051939450600093929091169163fc57d4df91602480820192602092909190829003018186803b15801561322257600080fd5b505afa158015613236573d6000803e3d6000fd5b505050506040513d602081101561324c57600080fd5b5051905081158061325b575080155b1561327057600d935060009250613369915050565b6000866001600160a01b031663182df0f56040518163ffffffff1660e01b815260040160206040518083038186803b1580156132ab57600080fd5b505afa1580156132bf573d6000803e3d6000fd5b505050506040513d60208110156132d557600080fd5b5051905060006132e36158a9565b6132eb6158a9565b6132f36158a9565b61331b604051806020016040528060065481525060405180602001604052808a815250615234565b9250613343604051806020016040528088815250604051806020016040528088815250615234565b915061334f8383615273565b905061335b818b614d32565b600099509750505050505050505b935093915050565b601360209081526000928352604080842090915290825290205481565b600a54600090600160b81b900460ff16156133e2576040805162461bcd60e51b815260206004820152600f60248201526e1cd95a5e99481a5cc81c185d5cd959608a1b604482015290519081900360640190fd5b6001600160a01b03861660009081526009602052604090205460ff16158061342357506001600160a01b03851660009081526009602052604090205460ff16155b1561342f5760096124d3565b846001600160a01b0316635fe3b5676040518163ffffffff1660e01b815260040160206040518083038186803b15801561346857600080fd5b505afa15801561347c573d6000803e3d6000fd5b505050506040513d602081101561349257600080fd5b505160408051635fe3b56760e01b815290516001600160a01b0392831692891691635fe3b567916004808301926020929190829003018186803b1580156134d857600080fd5b505afa1580156134ec573d6000803e3d6000fd5b505050506040513d602081101561350257600080fd5b50516001600160a01b0316146135195760026124d3565b6135228661495c565b61352c8684614af0565b6135368685614af0565b60009695505050505050565b6001600160a01b0383166000908152600c602052604081205460ff16156135a3576040805162461bcd60e51b815260206004820152601060248201526f189bdc9c9bddc81a5cc81c185d5cd95960821b604482015290519081900360640190fd5b6001600160a01b03841660009081526009602052604090205460ff166135ca576009612238565b6001600160a01b038085166000908152600960209081526040808320938716835260029093019052205460ff166136ba57336001600160a01b03851614613650576040805162461bcd60e51b815260206004820152601560248201527439b2b73232b91036bab9ba1031329030aa37b5b2b760591b604482015290519081900360640190fd5b600061365c338561513e565b9050600081601181111561366c57fe5b146136855780601181111561367d57fe5b915050611ee1565b6001600160a01b038086166000908152600960209081526040808320938816835260029093019052205460ff166136b857fe5b505b600480546040805163fc57d4df60e01b81526001600160a01b03888116948201949094529051929091169163fc57d4df91602480820192602092909190829003018186803b15801561370b57600080fd5b505afa15801561371f573d6000803e3d6000fd5b505050506040513d602081101561373557600080fd5b505161374257600d612238565b6001600160a01b038416600090815260166020526040902054801561382f576000856001600160a01b03166347bd37186040518163ffffffff1660e01b815260040160206040518083038186803b15801561379c57600080fd5b505afa1580156137b0573d6000803e3d6000fd5b505050506040513d60208110156137c657600080fd5b5051905060006137d6828661420d565b905082811061382c576040805162461bcd60e51b815260206004820152601960248201527f6d61726b657420626f72726f7720636170207265616368656400000000000000604482015290519081900360640190fd5b50505b60008061383f8688600088614624565b9193509091506000905082601181111561385557fe5b146138705781601181111561386657fe5b9350505050611ee1565b801561387d576004613866565b6138856158a9565b6040518060200160405280896001600160a01b031663aa5af0fd6040518163ffffffff1660e01b815260040160206040518083038186803b1580156138c957600080fd5b505afa1580156138dd573d6000803e3d6000fd5b505050506040513d60208110156138f357600080fd5b505190529050613903888261427d565b61390e888883614490565b600098975050505050505050565b6008602052816000526040600020818154811061393557fe5b6000918252602090912001546001600160a01b03169150829050565b6003546001600160a01b031681565b613968614d93565b6139b9576040805162461bcd60e51b815260206004820152601c60248201527f6f6e6c792061646d696e2063616e207365742061727320737065656400000000604482015290519081900360640190fd5b82518251811480156139cb5750815181145b613a065760405162461bcd60e51b8152600401808060200182810382526028815260200180615a2c6028913960400191505060405180910390fd5b60005b81811015611b7a57613a55858281518110613a2057fe5b6020026020010151858381518110613a3457fe5b6020026020010151858481518110613a4857fe5b60200260200101516152af565b600101613a09565b600080546001600160a01b03163314613a8357613a7c60016006614cac565b9050611a18565b6001600160a01b0383166000908152600960205260409020805460ff16613ab857613ab060096007614cac565b915050611a18565b613ac06158a9565b506040805160208101909152838152613ad76158a9565b506040805160208101909152670c7d713b49da00008152613af88183615492565b15613b1357613b0960066008614cac565b9350505050611a18565b8415801590613b9c5750600480546040805163fc57d4df60e01b81526001600160a01b038a8116948201949094529051929091169163fc57d4df91602480820192602092909190829003018186803b158015613b6e57600080fd5b505afa158015613b82573d6000803e3d6000fd5b505050506040513d6020811015613b9857600080fd5b5051155b15613bad57613b09600d6009614cac565b60018301805490869055604080516001600160a01b03891681526020810183905280820188905290517f70483e6592cd5182d45ac970e05bc62cdcc90e9d8ef2c2dbe686cf383bcd7fc59181900360600190a16000979650505050505050565b601260209081526000928352604080842090915290825290205481565b600a54600160a81b900460ff1681565b60055481565b600080613c4e858585614f58565b90508015613c5d579050611ee1565b613c668561495c565b613c708585614af0565b600095945050505050565b60146020526000908152604090205481565b6000808290506000806000836001600160a01b031663c37f68e2336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060806040518083038186803b158015613cee57600080fd5b505afa158015613d02573d6000803e3d6000fd5b505050506040513d6080811015613d1857600080fd5b508051602082015160409092015190945090925090508215613d6b5760405162461bcd60e51b8152600401808060200182810382526025815260200180615a896025913960400191505060405180910390fd5b8015613d8857613d7d600c6002614cac565b945050505050611e0c565b6000613d95873385614f58565b90508015613db657613daa600e600383615499565b95505050505050611e0c565b6001600160a01b0385166000908152600960209081526040808320338452600281019092529091205460ff16613df55760009650505050505050611e0c565b3360009081526002820160209081526040808320805460ff191690556008825291829020805483518184028101840190945280845260609392830182828015613e6757602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613e49575b5050835193945083925060009150505b82811015613ebc57896001600160a01b0316848281518110613e9557fe5b60200260200101516001600160a01b03161415613eb457809150613ebc565b600101613e77565b50818110613ec657fe5b336000908152600860205260409020805481906000198101908110613ee757fe5b9060005260206000200160009054906101000a90046001600160a01b0316818381548110613f1157fe5b600091825260209091200180546001600160a01b0319166001600160a01b03929092169190911790558054613f4a8260001983016158bc565b50604080516001600160a01b038c16815233602082015281517fe699a64c18b07ac5b7301aa273f36a2287239eb9501d81950672794afba29a0d929181900390910190a160009c9b505050505050505050505050565b601b5460ff1681565b6000546001600160a01b031681565b601c6020526000908152604090205481565b60005b835181101561416f576000848281518110613fe457fe5b6020908102919091018101516001600160a01b0381166000908152600990925260409091205490915060ff16614059576040805162461bcd60e51b81526020600482015260156024820152741b585c9ad95d081b5d5cdd081899481b1a5cdd1959605a1b604482015290519081900360640190fd5b6001841515141561411f5761406c6158a9565b6040518060200160405280836001600160a01b031663aa5af0fd6040518163ffffffff1660e01b815260040160206040518083038186803b1580156140b057600080fd5b505afa1580156140c4573d6000803e3d6000fd5b505050506040513d60208110156140da57600080fd5b5051905290506140ea828261427d565b60005b875181101561411c576141148389838151811061410657fe5b602002602001015184614490565b6001016140ed565b50505b60018315151415614166576141338161495c565b60005b86518110156141645761415c8288838151811061414f57fe5b6020026020010151614af0565b600101614136565b505b50600101613fcd565b5060005b8451811015611b7a576141d185828151811061418b57fe5b6020026020010151601460008885815181106141a357fe5b60200260200101516001600160a01b03166001600160a01b0316815260200190815260200160002054615004565b601460008784815181106141e157fe5b6020908102919091018101516001600160a01b0316825281019190915260400160002055600101614173565b6000611ee18383604051806040016040528060118152602001706164646974696f6e206f766572666c6f7760781b8152506154ff565b6000611ee18383604051806040016040528060158152602001747375627472616374696f6e20756e646572666c6f7760581b81525061559a565b6001600160a01b0382166000908152601160209081526040808320601990925282205490916142e86142ad612157565b6040518060400160405280601c81526020017f626c6f636b206e756d62657220657863656564732033322062697473000000008152506155f4565b835490915060009061430a9063ffffffff80851691600160e01b900416614243565b905060008111801561431c5750600083115b15614465576000614391876001600160a01b03166347bd37186040518163ffffffff1660e01b815260040160206040518083038186803b15801561435f57600080fd5b505afa158015614373573d6000803e3d6000fd5b505050506040513d602081101561438957600080fd5b505187615651565b9050600061439f8386614d51565b90506143a96158a9565b600083116143c657604051806020016040528060008152506143d0565b6143d0828461566f565b604080516020810190915288546001600160e01b03168152909150614433906143f990836156a3565b5160408051808201909152601a81527f6e657720696e646578206578636565647320323234206269747300000000000060208201526156c8565b87546001600160e01b0319166001600160e01b039182161716600160e01b63ffffffff8716021787555061215c915050565b801561215c57835463ffffffff8316600160e01b026001600160e01b03909116178455505050505050565b6001600160a01b03838116600090815260116020908152604080832080546013845282852095881685529490925290912080546001600160e01b03909316908190559091801580156144f057506a0c097ce7bc90715b34b9f160241b8210155b1561450657506a0c097ce7bc90715b34b9f160241b5b61450e6158a9565b60405180602001604052806145238585614243565b81525090506000614583886001600160a01b03166395dd9193896040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561435f57600080fd5b90506000614591828461571d565b6001600160a01b038916600090815260146020526040812054919250906145b8908361420d565b6001600160a01b03808b1660008181526014602090815260409182902085905581518781529081018b905281519495509193928e16927f83348684403d6ac51e18549a12cc3a7e465794414a2a124e4f80dfdf1019e53c9281900390910190a350505050505050505050565b60008060006146316158e0565b6001600160a01b0388166000908152600860209081526040808320805482518185028101850190935280835260609383018282801561469957602002820191906000526020600020905b81546001600160a01b0316815260019091019060200180831161467b575b50939450600093505050505b815181101561491d5760008282815181106146bc57fe5b60200260200101519050806001600160a01b031663c37f68e28d6040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060806040518083038186803b15801561471c57600080fd5b505afa158015614730573d6000803e3d6000fd5b505050506040513d608081101561474657600080fd5b508051602082015160408084015160609485015160808b015293890193909352918701919091529350831561478b5750600f9650600095508594506121ac9350505050565b60408051602080820183526001600160a01b0380851660008181526009845285902060010154845260c08a01939093528351808301855260808a0151815260e08a015260048054855163fc57d4df60e01b815291820194909452935192169263fc57d4df9260248083019392829003018186803b15801561480b57600080fd5b505afa15801561481f573d6000803e3d6000fd5b505050506040513d602081101561483557600080fd5b505160a086018190526148585750600d9650600095508594506121ac9350505050565b604080516020810190915260a0860151815261010086015260c085015160e08601516148929161488791615234565b866101000151615234565b6101208601819052604086015186516148ac92919061574b565b8552610100850151606086015160208701516148c992919061574b565b60208601526001600160a01b03818116908c161415614914576148f68561012001518b876020015161574b565b6020860181905261010086015161490e918b9061574b565b60208601525b506001016146a5565b5060208301518351111561494357505060208101519051600094500391508290506121ac565b50508051602090910151600094508493500390506121ac565b6001600160a01b0381166000908152601060209081526040808320601a909252822054909161498c6142ad612157565b83549091506000906149ae9063ffffffff80851691600160e01b900416614243565b90506000811180156149c05750600083115b15614ac6576000856001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b158015614a0057600080fd5b505afa158015614a14573d6000803e3d6000fd5b505050506040513d6020811015614a2a57600080fd5b505190506000614a3a8386614d51565b9050614a446158a9565b60008311614a615760405180602001604052806000815250614a6b565b614a6b828461566f565b604080516020810190915288546001600160e01b03168152909150614a94906143f990836156a3565b87546001600160e01b0319166001600160e01b039182161716600160e01b63ffffffff87160217875550611b7a915050565b8015611b7a57835463ffffffff8316600160e01b026001600160e01b039091161784555050505050565b6001600160a01b03828116600090815260106020908152604080832080546012845282852095871685529490925290912080546001600160e01b0390931690819055909180158015614b5057506a0c097ce7bc90715b34b9f160241b8210155b15614b6657506a0c097ce7bc90715b34b9f160241b5b614b6e6158a9565b6040518060200160405280614b838585614243565b81525090506000866001600160a01b03166370a08231876040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015614be057600080fd5b505afa158015614bf4573d6000803e3d6000fd5b505050506040513d6020811015614c0a57600080fd5b505190506000614c1a828461571d565b6001600160a01b03881660009081526014602052604081205491925090614c41908361420d565b6001600160a01b03808a1660008181526014602090815260409182902085905581518781529081018b905281519495509193928d16927ffe677a2e8dc3132dc6e90589abb43c35d2fb5fe958ba09bef482f5e41bf6506f9281900390910190a3505050505050505050565b60007f45b96fe442630264581b197e84bbada861235052c5a1aadfff9ea4e40a969aa0836011811115614cdb57fe5b836013811115614ce757fe5b604080519283526020830191909152600082820152519081900360600190a1826011811115611ee157fe5b6000806000614d25846000806000614624565b9250925092509193909250565b6000614d3c6158a9565b614d468484615773565b9050611cb181615794565b6000611ee183836040518060400160405280601781526020017f6d756c7469706c69636174696f6e206f766572666c6f770000000000000000008152506157a3565b600080546001600160a01b0316331480614db757506002546001600160a01b031633145b905090565b60005b600d54811015614e4757816001600160a01b0316600d8281548110614de057fe5b6000918252602090912001546001600160a01b03161415614e3f576040805162461bcd60e51b81526020600482015260146024820152731b585c9ad95d08185b1c9958591e48185919195960621b604482015290519081900360640190fd5b600101614dbf565b50600d80546001810182556000919091527fd7b6990105719101dabeb77144f2a3385c8033acd3af97e9423a695e81ad1eb50180546001600160a01b0319166001600160a01b0392909216919091179055565b6000614ea76142ad612157565b6001600160a01b03831660009081526010602090815260408083206011909252909120815492935090916001600160e01b0316614efd5781546001600160e01b0319166a0c097ce7bc90715b34b9f160241b1782555b80546001600160e01b0316614f2b5780546001600160e01b0319166a0c097ce7bc90715b34b9f160241b1781555b805463ffffffff909316600160e01b026001600160e01b0393841681179091558154909216909117905550565b6001600160a01b03831660009081526009602052604081205460ff16614f7f576009612238565b6001600160a01b038085166000908152600960209081526040808320938716835260029093019052205460ff16614fb7576000612238565b600080614fc78587866000614624565b91935090915060009050826011811115614fdd57fe5b14614ff757816011811115614fee57fe5b92505050611ee1565b8015613536576004614fee565b60008061500f612c5c565b604080516370a0823160e01b815230600482015290519192506000916001600160a01b038416916370a08231916024808301926020929190829003018186803b15801561505b57600080fd5b505afa15801561506f573d6000803e3d6000fd5b505050506040513d602081101561508557600080fd5b5051905083158015906150985750808411155b1561513557816001600160a01b031663a9059cbb86866040518363ffffffff1660e01b815260040180836001600160a01b03166001600160a01b0316815260200182815260200192505050602060405180830381600087803b1580156150fd57600080fd5b505af1158015615111573d6000803e3d6000fd5b505050506040513d602081101561512757600080fd5b5060009350611a1892505050565b50919392505050565b6001600160a01b0382166000908152600960205260408120805460ff16615169576009915050611a18565b6001600160a01b038316600090815260028201602052604090205460ff1615156001141561519b576000915050611a18565b6001600160a01b0380841660008181526002840160209081526040808320805460ff19166001908117909155600883528184208054918201815584529282902090920180549489166001600160a01b031990951685179055815193845283019190915280517f3ab23ab0d51cccc0c3085aec51f99228625aa1a922b3a8ca89a26b0f2027a1a59281900390910190a15060009392505050565b61523c6158a9565b6040518060200160405280670de0b6b3a764000061526286600001518660000151614d51565b8161526957fe5b0490529392505050565b61527b6158a9565b60405180602001604052806152a661529f8660000151670de0b6b3a7640000614d51565b8551615819565b90529392505050565b6001600160a01b0383166000908152600960205260409020805460ff1661531d576040805162461bcd60e51b815260206004820152601860248201527f617273206d61726b6574206973206e6f74206c69737465640000000000000000604482015290519081900360640190fd5b6001600160a01b0384166000908152601a60205260409020548314615396576153458461495c565b6001600160a01b0384166000818152601a6020908152604091829020869055815186815291517f8a77ffafc8248b67a55cb39312a8d84f9591f4b2f127d5bcb48d3503e8a0881e9281900390910190a25b6001600160a01b0384166000908152601960205260409020548214612151576153bd6158a9565b6040518060200160405280866001600160a01b031663aa5af0fd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561540157600080fd5b505afa158015615415573d6000803e3d6000fd5b505050506040513d602081101561542b57600080fd5b50519052905061543b858261427d565b6001600160a01b038516600081815260196020908152604091829020869055815186815291517f28296fac6da7787338cb53d8f6b0ade25db8a2c319ced8de99a06c3e050ca71d9281900390910190a25050505050565b5190511090565b60007f45b96fe442630264581b197e84bbada861235052c5a1aadfff9ea4e40a969aa08460118111156154c857fe5b8460138111156154d457fe5b604080519283526020830191909152818101859052519081900360600190a1836011811115611cb157fe5b600083830182858210156155915760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561555657818101518382015260200161553e565b50505050905090810190601f1680156155835780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b50949350505050565b600081848411156155ec5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561555657818101518382015260200161553e565b505050900390565b600081600160201b84106156495760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561555657818101518382015260200161553e565b509192915050565b6000611ee161566884670de0b6b3a7640000614d51565b8351615819565b6156776158a9565b60405180602001604052806152a661569d866a0c097ce7bc90715b34b9f160241b614d51565b85615819565b6156ab6158a9565b60405180602001604052806152a68560000151856000015161420d565b600081600160e01b84106156495760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561555657818101518382015260200161553e565b60006a0c097ce7bc90715b34b9f160241b61573c848460000151614d51565b8161574357fe5b049392505050565b60006157556158a9565b61575f8585615773565b905061263861576d82615794565b8461420d565b61577b6158a9565b60405180602001604052806152a6856000015185614d51565b51670de0b6b3a7640000900490565b60008315806157b0575082155b156157bd57506000611ee1565b838302838582816157ca57fe5b041483906155915760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561555657818101518382015260200161553e565b6000611ee183836040518060400160405280600e81526020016d646976696465206279207a65726f60901b815250600081836158965760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561555657818101518382015260200161553e565b508284816158a057fe5b04949350505050565b6040518060200160405280600081525090565b815481835581811115611bed57600083815260209020611bed91810190830161594a565b60405180610140016040528060008152602001600081526020016000815260200160008152602001600081526020016000815260200161591e6158a9565b815260200161592b6158a9565b81526020016159386158a9565b81526020016159456158a9565b905290565b61215991905b808211156159645760008155600101615950565b509056fe63616e6e6f742070617573652061206d61726b65742074686174206973206e6f74206c697374656443616e206e6f74207265706179206d6f7265207468616e2074686520746f74616c20626f72726f77416c72656164792065786563757465642074686973206f6e652d6f66662066756e6374696f6e6f6e6c7920706175736520677561726469616e20616e642061646d696e2063616e2070617573656f6e6c792061646d696e2063616e2073657420626f72726f772063617020677561726469616e436f6d7074726f6c6c65723a3a5f73657441727353706565647320696e76616c696420696e7075746f6e6c792061646d696e206f7220626f72726f772063617020677561726469616e2063616e2073657420626f72726f772063617073657869744d61726b65743a206765744163636f756e74536e617073686f74206661696c65644f6e6c792061646d696e2063616e2063616c6c20746869732066756e6374696f6e6f6e6c7920756e6974726f6c6c65722061646d696e2063616e206368616e676520627261696e73a265627a7a7231582011d51fbd4e0a03c138e2cbdbd71d79a896490f2a738a9e23bbff09fdce256dbb64736f6c63430005110032

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061048a5760003560e01c8063731f0c2b11610262578063bea6b8b811610151578063e4028eee116100ce578063ec1b16de11610092578063ec1b16de146113ea578063ede4edd014611410578063f00a7a9214611436578063f851a4401461143e578063fa47f47d14611446578063fe815df71461146c5761048a565b8063e4028eee1461134a578063e5037f1414611376578063e6653f3d146113a4578063e8755446146113ac578063eabe7d91146113b45761048a565b8063d02f735111610115578063d02f7351146110f5578063da3d454c1461113b578063dce1544914611171578063dcfbc0c71461119d578063e3404c8a146111a55761048a565b8063bea6b8b814610f85578063bf15912314610fab578063c299823814610fd7578063c488847b14611078578063c63fdc4b146110c75761048a565b806394d3001f116101df578063abfceffc116101a3578063abfceffc14610ebb578063ac0b0bb714610f31578063b0772d0b14610f39578063bb82aa5e14610f41578063bdcdc25814610f495761048a565b806394d3001f14610e155780639d10433d14610e415780639e1fce0b14610e67578063a76b3fda14610e6f578063a9d9a97114610e955761048a565b80638e8f294b116102265780638e8f294b14610d525780638ebf636414610d9a578063929fe9a114610db957806394543c1514610de757806394b2294b14610e0d5761048a565b8063731f0c2b14610cee578063741b252514610d14578063768e3dc414610d3a5780637dc0d1d014610d4257806387f7630314610d4a5761048a565b806341c728b91161037e57806355ee1fe1116102fb578063607ef6c1116102bf578063607ef6c114610b625780636919de6314610c205780636a56947e14610c465780636d154ea514610c825780636d35bf9114610ca85761048a565b806355ee1fe114610a745780635c77860514610a9a5780635ec88c7914610ad05780635f5af1aa14610af65780635fc7e71e14610b1c5761048a565b80634e79238f116103425780634e79238f1461096e5780634ef4c3e1146109c85780634fd42e17146109fe57806351dff98914610a1b57806352d84d1e14610a575761048a565b806341c728b9146108b057806342cbb15c146108ec57806347ef3b3b146108f45780634a584432146109405780634ada90af146109665761048a565b806324008a621161040c578063317b0b77116103d0578063317b0b7714610811578063391957d71461082e5780633bcf7ec1146108545780633c94786f146108825780633e2d72111461088a5761048a565b806324008a621461075857806324a3d62214610794578063267822471461079c5780632d70db78146107a45780632f040ee8146107c35761048a565b806318c882a51161045357806318c882a5146105ed5780631d504dc61461061b5780631ededc911461064157806321af45691461068357806322f81391146106a75761048a565b80627e3dd21461048f57806302147658146104ab5780631125d627146104cf57806316b95e8f1461050757806317efa2c2146105c7575b600080fd5b610497611598565b604080519115158252519081900360200190f35b6104b361159d565b604080516001600160e01b039092168252519081900360200190f35b6104f5600480360360208110156104e557600080fd5b50356001600160a01b03166115af565b60408051918252519081900360200190f35b6105c56004803603604081101561051d57600080fd5b810190602081018135600160201b81111561053757600080fd5b82018360208201111561054957600080fd5b803590602001918460208302840111600160201b8311171561056a57600080fd5b919390929091602081019035600160201b81111561058757600080fd5b82018360208201111561059957600080fd5b803590602001918460208302840111600160201b831117156105ba57600080fd5b5090925090506115c1565b005b6105c5600480360360208110156105dd57600080fd5b50356001600160a01b0316611817565b6104976004803603604081101561060357600080fd5b506001600160a01b038135169060200135151561187e565b6105c56004803603602081101561063157600080fd5b50356001600160a01b0316611a1e565b6105c5600480360360a081101561065757600080fd5b506001600160a01b03813581169160208101358216916040820135169060608101359060800135611b7a565b61068b611b81565b604080516001600160a01b039092168252519081900360200190f35b6105c5600480360360408110156106bd57600080fd5b6001600160a01b038235169190810190604081016020820135600160201b8111156106e757600080fd5b8201836020820111156106f957600080fd5b803590602001918460208302840111600160201b8311171561071a57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550611b90945050505050565b6104f56004803603608081101561076e57600080fd5b506001600160a01b03813581169160208101358216916040820135169060600135611bf2565b61068b611cb9565b61068b611cc8565b610497600480360360208110156107ba57600080fd5b50351515611cd7565b6107e9600480360360208110156107d957600080fd5b50356001600160a01b0316611e11565b604080516001600160e01b03909316835263ffffffff90911660208301528051918290030190f35b6104f56004803603602081101561082757600080fd5b5035611e3b565b6105c56004803603602081101561084457600080fd5b50356001600160a01b0316611ee8565b6104976004803603604081101561086a57600080fd5b506001600160a01b0381351690602001351515611f94565b61049761212f565b6104f5600480360360208110156108a057600080fd5b50356001600160a01b031661213f565b6105c5600480360360808110156108c657600080fd5b506001600160a01b03813581169160208101359091169060408101359060600135612151565b6104f5612157565b6105c5600480360360c081101561090a57600080fd5b506001600160a01b0381358116916020810135821691604082013581169160608101359091169060808101359060a0013561215c565b6104f56004803603602081101561095657600080fd5b50356001600160a01b0316612164565b6104f5612176565b6109aa6004803603608081101561098457600080fd5b506001600160a01b0381358116916020810135909116906040810135906060013561217c565b60408051938452602084019290925282820152519081900360600190f35b6104f5600480360360608110156109de57600080fd5b506001600160a01b038135811691602081013590911690604001356121b6565b6104f560048036036020811015610a1457600080fd5b503561225c565b6105c560048036036080811015610a3157600080fd5b506001600160a01b038135811691602081013590911690604081013590606001356122cc565b61068b60048036036020811015610a6d57600080fd5b5035612320565b6104f560048036036020811015610a8a57600080fd5b50356001600160a01b0316612347565b6105c560048036036060811015610ab057600080fd5b506001600160a01b038135811691602081013590911690604001356123cc565b6109aa60048036036020811015610ae657600080fd5b50356001600160a01b03166123d1565b6104f560048036036020811015610b0c57600080fd5b50356001600160a01b0316612406565b6104f5600480360360a0811015610b3257600080fd5b506001600160a01b038135811691602081013582169160408201358116916060810135909116906080013561248a565b6105c560048036036040811015610b7857600080fd5b810190602081018135600160201b811115610b9257600080fd5b820183602082011115610ba457600080fd5b803590602001918460208302840111600160201b83111715610bc557600080fd5b919390929091602081019035600160201b811115610be257600080fd5b820183602082011115610bf457600080fd5b803590602001918460208302840111600160201b83111715610c1557600080fd5b509092509050612641565b6104f560048036036020811015610c3657600080fd5b50356001600160a01b03166127d1565b6105c560048036036080811015610c5c57600080fd5b506001600160a01b03813581169160208101358216916040820135169060600135612151565b61049760048036036020811015610c9857600080fd5b50356001600160a01b03166127e3565b6105c5600480360360a0811015610cbe57600080fd5b506001600160a01b0381358116916020810135821691604082013581169160608101359091169060800135611b7a565b61049760048036036020811015610d0457600080fd5b50356001600160a01b03166127f8565b6105c560048036036020811015610d2a57600080fd5b50356001600160a01b031661280d565b6104f56128d0565b61068b6128d6565b6104976128e5565b610d7860048036036020811015610d6857600080fd5b50356001600160a01b03166128f5565b6040805193151584526020840192909252151582820152519081900360600190f35b61049760048036036020811015610db057600080fd5b5035151561291b565b61049760048036036040811015610dcf57600080fd5b506001600160a01b0381358116916020013516612a54565b61049760048036036020811015610dfd57600080fd5b50356001600160a01b0316612a87565b6104f5612b49565b6105c560048036036040811015610e2b57600080fd5b506001600160a01b038135169060200135612b4f565b6104f560048036036020811015610e5757600080fd5b50356001600160a01b0316612c4a565b61068b612c5c565b6104f560048036036020811015610e8557600080fd5b50356001600160a01b0316612c74565b6107e960048036036020811015610eab57600080fd5b50356001600160a01b0316612dd9565b610ee160048036036020811015610ed157600080fd5b50356001600160a01b0316612e03565b60408051602080825283518183015283519192839290830191858101910280838360005b83811015610f1d578181015183820152602001610f05565b505050509050019250505060405180910390f35b610497612e8c565b610ee1612e9c565b61068b612efe565b6104f560048036036080811015610f5f57600080fd5b506001600160a01b03813581169160208101358216916040820135169060600135612f0d565b6104f560048036036020811015610f9b57600080fd5b50356001600160a01b0316612f9d565b6105c560048036036040811015610fc157600080fd5b506001600160a01b038135169060200135612faf565b610ee160048036036020811015610fed57600080fd5b810190602081018135600160201b81111561100757600080fd5b82018360208201111561101957600080fd5b803590602001918460208302840111600160201b8311171561103a57600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295506130b2945050505050565b6110ae6004803603606081101561108e57600080fd5b506001600160a01b03813581169160208101359091169060400135613149565b6040805192835260208301919091528051918290030190f35b6104f5600480360360408110156110dd57600080fd5b506001600160a01b0381358116916020013516613371565b6104f5600480360360a081101561110b57600080fd5b506001600160a01b038135811691602081013582169160408201358116916060810135909116906080013561338e565b6104f56004803603606081101561115157600080fd5b506001600160a01b03813581169160208101359091169060400135613542565b61068b6004803603604081101561118757600080fd5b506001600160a01b03813516906020013561391c565b61068b613951565b6105c5600480360360608110156111bb57600080fd5b810190602081018135600160201b8111156111d557600080fd5b8201836020820111156111e757600080fd5b803590602001918460208302840111600160201b8311171561120857600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295949360208101935035915050600160201b81111561125757600080fd5b82018360208201111561126957600080fd5b803590602001918460208302840111600160201b8311171561128a57600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295949360208101935035915050600160201b8111156112d957600080fd5b8201836020820111156112eb57600080fd5b803590602001918460208302840111600160201b8311171561130c57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550613960945050505050565b6104f56004803603604081101561136057600080fd5b506001600160a01b038135169060200135613a5d565b6104f56004803603604081101561138c57600080fd5b506001600160a01b0381358116916020013516613c0d565b610497613c2a565b6104f5613c3a565b6104f5600480360360608110156113ca57600080fd5b506001600160a01b03813581169160208101359091169060400135613c40565b6104f56004803603602081101561140057600080fd5b50356001600160a01b0316613c7b565b6104f56004803603602081101561142657600080fd5b50356001600160a01b0316613c8d565b610497613fa0565b61068b613fa9565b6104f56004803603602081101561145c57600080fd5b50356001600160a01b0316613fb8565b6105c56004803603608081101561148257600080fd5b810190602081018135600160201b81111561149c57600080fd5b8201836020820111156114ae57600080fd5b803590602001918460208302840111600160201b831117156114cf57600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295949360208101935035915050600160201b81111561151e57600080fd5b82018360208201111561153057600080fd5b803590602001918460208302840111600160201b8311171561155157600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550505050803515159150602001351515613fca565b600181565b6a0c097ce7bc90715b34b9f160241b81565b60176020526000908152604090205481565b6000546001600160a01b0316331461160a5760405162461bcd60e51b8152600401808060200182810382526021815260200180615aae6021913960400191505060405180910390fd5b601b5460ff161561164c5760405162461bcd60e51b81526004018080602001828103825260268152602001806159b96026913960400191505060405180910390fd5b828114611690576040805162461bcd60e51b815260206004820152600d60248201526c125b9d985b1a59081a5b9c1d5d609a1b604482015290519081900360640190fd5b6000808080805b878110156117ff578888828181106116ab57fe5b905060200201356001600160a01b0316945060146000866001600160a01b03166001600160a01b031681526020019081526020016000205493508686828181106116f157fe5b9050602002013592508383111561178b576001600160a01b0385166000908152601c602052604081205485850391611729828461420d565b6001600160a01b0389166000818152601c60209081526040918290208490558151868152908101849052815193945091927f66fef805789c572d318945f327c22008b0f90ffeba0980b1404981695df3c4f89281900390910190a28695505050505b82156117f75761179b8484614243565b6001600160a01b0386166000818152601460209081526040918290208490558151888152908101849052815193955091927f24fad61822f6b333328e372b501c762eca75f16cd45e1f2c7a916ebece34a35c9281900390910190a25b600101611697565b5050601b805460ff1916600117905550505050505050565b61187b81600d80548060200260200160405190810160405280929190818152602001828054801561187157602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311611853575b5050505050611b90565b50565b6001600160a01b03821660009081526009602052604081205460ff166118d55760405162461bcd60e51b81526004018080602001828103825260288152602001806159696028913960400191505060405180910390fd5b600a546001600160a01b03163314806118f857506000546001600160a01b031633145b6119335760405162461bcd60e51b81526004018080602001828103825260278152602001806159df6027913960400191505060405180910390fd5b6000546001600160a01b031633148061194e57506001821515145b611998576040805162461bcd60e51b81526020600482015260166024820152756f6e6c792061646d696e2063616e20756e706175736560501b604482015290519081900360640190fd5b6001600160a01b0383166000818152600c6020908152604091829020805486151560ff199091168117909155825193845283830152606090830181905260069083015265426f72726f7760d01b6080830152517f71aec636243f9709bb0007ae15e9afb8150ab01716d75fd7573be5cc096e03b09181900360a00190a150805b92915050565b806001600160a01b031663f851a4406040518163ffffffff1660e01b815260040160206040518083038186803b158015611a5757600080fd5b505afa158015611a6b573d6000803e3d6000fd5b505050506040513d6020811015611a8157600080fd5b50516001600160a01b03163314611ac95760405162461bcd60e51b8152600401808060200182810382526027815260200180615acf6027913960400191505060405180910390fd5b806001600160a01b031663c1e803346040518163ffffffff1660e01b8152600401602060405180830381600087803b158015611b0457600080fd5b505af1158015611b18573d6000803e3d6000fd5b505050506040513d6020811015611b2e57600080fd5b50511561187b576040805162461bcd60e51b815260206004820152601560248201527418da185b99d9481b9bdd08185d5d1a1bdc9a5e9959605a1b604482015290519081900360640190fd5b5050505050565b6015546001600160a01b031681565b604080516001808252818301909252606091602080830190803883390190505090508281600081518110611bc057fe5b60200260200101906001600160a01b031690816001600160a01b031681525050611bed8183600180613fca565b505050565b6001600160a01b03841660009081526009602052604081205460ff16611c1a57506009611cb1565b611c226158a9565b6040518060200160405280876001600160a01b031663aa5af0fd6040518163ffffffff1660e01b815260040160206040518083038186803b158015611c6657600080fd5b505afa158015611c7a573d6000803e3d6000fd5b505050506040513d6020811015611c9057600080fd5b505190529050611ca0868261427d565b611cab868583614490565b60009150505b949350505050565b600a546001600160a01b031681565b6001546001600160a01b031681565b600a546000906001600160a01b0316331480611cfd57506000546001600160a01b031633145b611d385760405162461bcd60e51b81526004018080602001828103825260278152602001806159df6027913960400191505060405180910390fd5b6000546001600160a01b0316331480611d5357506001821515145b611d9d576040805162461bcd60e51b81526020600482015260166024820152756f6e6c792061646d696e2063616e20756e706175736560501b604482015290519081900360640190fd5b600a8054831515600160b81b810260ff60b81b1990921691909117909155604080516020810192909252808252600582820152645365697a6560d81b6060830152517fef159d9a32b2472e32b098f954f3ce62d232939f1c207070b584df1814de2de09181900360800190a150805b919050565b6010602052600090815260409020546001600160e01b03811690600160e01b900463ffffffff1682565b600080546001600160a01b03163314611e9b576040805162461bcd60e51b815260206004820152601f60248201527f6f6e6c792061646d696e2063616e2073657420636c6f736520666163746f7200604482015290519081900360640190fd5b6005805490839055604080518281526020810185905281517f3b9670cf975d26958e754b57098eaa2ac914d8d2a31b83257997b9f346110fd9929181900390910190a160005b9392505050565b6000546001600160a01b03163314611f315760405162461bcd60e51b8152600401808060200182810382526026815260200180615a066026913960400191505060405180910390fd5b601580546001600160a01b038381166001600160a01b0319831681179093556040805191909216808252602082019390935281517feda98690e518e9a05f8ec6837663e188211b2da8f4906648b323f2c1d4434e29929181900390910190a15050565b6001600160a01b03821660009081526009602052604081205460ff16611feb5760405162461bcd60e51b81526004018080602001828103825260288152602001806159696028913960400191505060405180910390fd5b600a546001600160a01b031633148061200e57506000546001600160a01b031633145b6120495760405162461bcd60e51b81526004018080602001828103825260278152602001806159df6027913960400191505060405180910390fd5b6000546001600160a01b031633148061206457506001821515145b6120ae576040805162461bcd60e51b81526020600482015260166024820152756f6e6c792061646d696e2063616e20756e706175736560501b604482015290519081900360640190fd5b6001600160a01b0383166000818152600b6020908152604091829020805486151560ff199091168117909155825193845283830152606090830181905260049083015263135a5b9d60e21b6080830152517f71aec636243f9709bb0007ae15e9afb8150ab01716d75fd7573be5cc096e03b09181900360a00190a150919050565b600a54600160a01b900460ff1681565b600f6020526000908152604090205481565b50505050565b435b90565b505050505050565b60166020526000908152604090205481565b60065481565b6000806000806000806121918a8a8a8a614624565b9250925092508260118111156121a357fe5b95509093509150505b9450945094915050565b6001600160a01b0383166000908152600b602052604081205460ff1615612215576040805162461bcd60e51b815260206004820152600e60248201526d1b5a5b9d081a5cc81c185d5cd95960921b604482015290519081900360640190fd5b6001600160a01b03841660009081526009602052604090205460ff1661223f5760095b9050611ee1565b6122488461495c565b6122528484614af0565b6000949350505050565b600080546001600160a01b031633146122825761227b6001600b614cac565b9050611e0c565b6006805490839055604080518281526020810185905281517faeba5a6c40a8ac138134bff1aaa65debf25971188a58804bad717f82f0ec1316929181900390910190a16000611ee1565b801580156122da5750600082115b15612151576040805162461bcd60e51b815260206004820152601160248201527072656465656d546f6b656e73207a65726f60781b604482015290519081900360640190fd5b600d818154811061232d57fe5b6000918252602090912001546001600160a01b0316905081565b600080546001600160a01b031633146123665761227b60016010614cac565b600480546001600160a01b038481166001600160a01b0319831681179093556040805191909216808252602082019390935281517fd52b2b9b7e9ee655fcb95d2e5b9e0c9f69e7ef2b8e9d2d0ea78402d576d22e22929181900390910190a16000611ee1565b611bed565b6000806000806000806123e8876000806000614624565b9250925092508260118111156123fa57fe5b97919650945092505050565b600080546001600160a01b031633146124255761227b60016013614cac565b600a80546001600160a01b038481166001600160a01b0319831617928390556040805192821680845293909116602083015280517f0613b6ee6a04f0d09f390e4d9318894b9f6ac7fd83897cd8d18896ba579c401e9281900390910190a16000611ee1565b6001600160a01b03851660009081526009602052604081205460ff1615806124cb57506001600160a01b03851660009081526009602052604090205460ff16155b156124da5760095b9050612638565b6000866001600160a01b03166395dd9193856040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561253257600080fd5b505afa158015612546573d6000803e3d6000fd5b505050506040513d602081101561255c57600080fd5b5051905061256987612a87565b156125b257828110156125ad5760405162461bcd60e51b81526004018080602001828103825260288152602001806159916028913960400191505060405180910390fd5b612632565b6000806125be86614d12565b919350909150600090508260118111156125d457fe5b146125ef578160118111156125e557fe5b9350505050612638565b806125fb5760036125e5565b6000612617604051806020016040528060055481525085614d32565b90508086111561262e576011945050505050612638565b5050505b60009150505b95945050505050565b6000546001600160a01b031633148061266457506015546001600160a01b031633145b61269f5760405162461bcd60e51b8152600401808060200182810382526035815260200180615a546035913960400191505060405180910390fd5b828181158015906126af57508082145b6126f0576040805162461bcd60e51b815260206004820152600d60248201526c1a5b9d985b1a59081a5b9c1d5d609a1b604482015290519081900360640190fd5b60005b828110156127c85784848281811061270757fe5b905060200201356016600089898581811061271e57fe5b905060200201356001600160a01b03166001600160a01b03166001600160a01b031681526020019081526020016000208190555086868281811061275e57fe5b905060200201356001600160a01b03166001600160a01b03167f6f1951b2aad10f3fc81b86d91105b413a5b3f847a34bbc5ce1904201b14438f68686848181106127a457fe5b905060200201356040518082815260200191505060405180910390a26001016126f3565b50505050505050565b60196020526000908152604090205481565b600c6020526000908152604090205460ff1681565b600b6020526000908152604090205460ff1681565b6001600160a01b0381166000908152601760205260408120549061282f612157565b6001600160a01b03841660009081526018602052604081205491925090612857908390614243565b90506000811180156128695750600083115b1561215157600061287a8285614d51565b6001600160a01b038616600090815260146020526040812054919250906128a1908361420d565b6001600160a01b0387166000908152601460209081526040808320939093556018905220849055505050505050565b600e5481565b6004546001600160a01b031681565b600a54600160b01b900460ff1681565b60096020526000908152604090208054600182015460039092015460ff91821692911683565b600a546000906001600160a01b031633148061294157506000546001600160a01b031633145b61297c5760405162461bcd60e51b81526004018080602001828103825260278152602001806159df6027913960400191505060405180910390fd5b6000546001600160a01b031633148061299757506001821515145b6129e1576040805162461bcd60e51b81526020600482015260166024820152756f6e6c792061646d696e2063616e20756e706175736560501b604482015290519081900360640190fd5b600a8054831515600160b01b810260ff60b01b1990921691909117909155604080516020810192909252808252600882820152672a3930b739b332b960c11b6060830152517fef159d9a32b2472e32b098f954f3ce62d232939f1c207070b584df1814de2de09181900360800190a15090565b6001600160a01b038082166000908152600960209081526040808320938616835260029093019052205460ff1692915050565b6001600160a01b038116600090815260096020526040812060010154158015612acd57506001600160a01b0382166000908152600c602052604090205460ff1615156001145b8015611a185750816001600160a01b031663173b99046040518163ffffffff1660e01b815260040160206040518083038186803b158015612b0d57600080fd5b505afa158015612b21573d6000803e3d6000fd5b505050506040513d6020811015612b3757600080fd5b5051670de0b6b3a76400001492915050565b60075481565b612b57614d93565b612ba8576040805162461bcd60e51b815260206004820152601c60248201527f6f6e6c792061646d696e2063616e207365742061727320737065656400000000604482015290519081900360640190fd5b612bb18261280d565b80612bd4576001600160a01b038216600090815260186020526040812055612bf6565b612bdc612157565b6001600160a01b0383166000908152601860205260409020555b6001600160a01b038216600081815260176020908152604091829020849055815184815291517fad131fb09698eb20902388c161c2ca51da25735b495ea264868527e6cb196cb39281900390910190a25050565b601a6020526000908152604090205481565b738f57e33c1f7f6e2886eba9f83464e5b308d8320290565b600080546001600160a01b03163314612c935761227b60016012614cac565b6001600160a01b03821660009081526009602052604090205460ff1615612cc05761227b600a6011614cac565b816001600160a01b03166394c393fc6040518163ffffffff1660e01b815260040160206040518083038186803b158015612cf957600080fd5b505afa158015612d0d573d6000803e3d6000fd5b505050506040513d6020811015612d2357600080fd5b5050604080516060810182526001808252600060208381018281528486018381526001600160a01b03891684526009909252949091209251835490151560ff19918216178455935191830191909155516003909101805491151591909216179055612d8d82614dbc565b612d9682614e9a565b604080516001600160a01b038416815290517fcf583bb0c569eb967f806b11601c4cb93c10310485c67add5f8362c2f212321f9181900360200190a16000611a18565b6011602052600090815260409020546001600160e01b03811690600160e01b900463ffffffff1682565b60608060086000846001600160a01b03166001600160a01b03168152602001908152602001600020805480602002602001604051908101604052809291908181526020018280548015612e7f57602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311612e61575b5093979650505050505050565b600a54600160b81b900460ff1681565b6060600d805480602002602001604051908101604052809291908181526020018280548015612ef457602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311612ed6575b5050505050905090565b6002546001600160a01b031681565b600a54600090600160b01b900460ff1615612f64576040805162461bcd60e51b81526020600482015260126024820152711d1c985b9cd9995c881a5cc81c185d5cd95960721b604482015290519081900360640190fd5b6000612f71868685614f58565b90508015612f80579050611cb1565b612f898661495c565b612f938686614af0565b611cab8685614af0565b60186020526000908152604090205481565b612fb7614d93565b613008576040805162461bcd60e51b815260206004820152601860248201527f6f6e6c792061646d696e2063616e206772616e74206172730000000000000000604482015290519081900360640190fd5b60006130148383615004565b90508015613069576040805162461bcd60e51b815260206004820152601a60248201527f696e73756666696369656e742061727320666f72206772616e74000000000000604482015290519081900360640190fd5b604080516001600160a01b03851681526020810184905281517f0d9d61be0ce93f1896e1ca6ca63618fabc5e7ae514a306e75a21b521e8fb0b22929181900390910190a1505050565b60606000825190506060816040519080825280602002602001820160405280156130e6578160200160208202803883390190505b50905060005b8281101561314157600085828151811061310257fe5b60200260200101519050613116813361513e565b601181111561312157fe5b83838151811061312d57fe5b6020908102919091010152506001016130ec565b509392505050565b600480546040805163fc57d4df60e01b81526001600160a01b038781169482019490945290516000938493849391169163fc57d4df91602480820192602092909190829003018186803b15801561319f57600080fd5b505afa1580156131b3573d6000803e3d6000fd5b505050506040513d60208110156131c957600080fd5b5051600480546040805163fc57d4df60e01b81526001600160a01b038a8116948201949094529051939450600093929091169163fc57d4df91602480820192602092909190829003018186803b15801561322257600080fd5b505afa158015613236573d6000803e3d6000fd5b505050506040513d602081101561324c57600080fd5b5051905081158061325b575080155b1561327057600d935060009250613369915050565b6000866001600160a01b031663182df0f56040518163ffffffff1660e01b815260040160206040518083038186803b1580156132ab57600080fd5b505afa1580156132bf573d6000803e3d6000fd5b505050506040513d60208110156132d557600080fd5b5051905060006132e36158a9565b6132eb6158a9565b6132f36158a9565b61331b604051806020016040528060065481525060405180602001604052808a815250615234565b9250613343604051806020016040528088815250604051806020016040528088815250615234565b915061334f8383615273565b905061335b818b614d32565b600099509750505050505050505b935093915050565b601360209081526000928352604080842090915290825290205481565b600a54600090600160b81b900460ff16156133e2576040805162461bcd60e51b815260206004820152600f60248201526e1cd95a5e99481a5cc81c185d5cd959608a1b604482015290519081900360640190fd5b6001600160a01b03861660009081526009602052604090205460ff16158061342357506001600160a01b03851660009081526009602052604090205460ff16155b1561342f5760096124d3565b846001600160a01b0316635fe3b5676040518163ffffffff1660e01b815260040160206040518083038186803b15801561346857600080fd5b505afa15801561347c573d6000803e3d6000fd5b505050506040513d602081101561349257600080fd5b505160408051635fe3b56760e01b815290516001600160a01b0392831692891691635fe3b567916004808301926020929190829003018186803b1580156134d857600080fd5b505afa1580156134ec573d6000803e3d6000fd5b505050506040513d602081101561350257600080fd5b50516001600160a01b0316146135195760026124d3565b6135228661495c565b61352c8684614af0565b6135368685614af0565b60009695505050505050565b6001600160a01b0383166000908152600c602052604081205460ff16156135a3576040805162461bcd60e51b815260206004820152601060248201526f189bdc9c9bddc81a5cc81c185d5cd95960821b604482015290519081900360640190fd5b6001600160a01b03841660009081526009602052604090205460ff166135ca576009612238565b6001600160a01b038085166000908152600960209081526040808320938716835260029093019052205460ff166136ba57336001600160a01b03851614613650576040805162461bcd60e51b815260206004820152601560248201527439b2b73232b91036bab9ba1031329030aa37b5b2b760591b604482015290519081900360640190fd5b600061365c338561513e565b9050600081601181111561366c57fe5b146136855780601181111561367d57fe5b915050611ee1565b6001600160a01b038086166000908152600960209081526040808320938816835260029093019052205460ff166136b857fe5b505b600480546040805163fc57d4df60e01b81526001600160a01b03888116948201949094529051929091169163fc57d4df91602480820192602092909190829003018186803b15801561370b57600080fd5b505afa15801561371f573d6000803e3d6000fd5b505050506040513d602081101561373557600080fd5b505161374257600d612238565b6001600160a01b038416600090815260166020526040902054801561382f576000856001600160a01b03166347bd37186040518163ffffffff1660e01b815260040160206040518083038186803b15801561379c57600080fd5b505afa1580156137b0573d6000803e3d6000fd5b505050506040513d60208110156137c657600080fd5b5051905060006137d6828661420d565b905082811061382c576040805162461bcd60e51b815260206004820152601960248201527f6d61726b657420626f72726f7720636170207265616368656400000000000000604482015290519081900360640190fd5b50505b60008061383f8688600088614624565b9193509091506000905082601181111561385557fe5b146138705781601181111561386657fe5b9350505050611ee1565b801561387d576004613866565b6138856158a9565b6040518060200160405280896001600160a01b031663aa5af0fd6040518163ffffffff1660e01b815260040160206040518083038186803b1580156138c957600080fd5b505afa1580156138dd573d6000803e3d6000fd5b505050506040513d60208110156138f357600080fd5b505190529050613903888261427d565b61390e888883614490565b600098975050505050505050565b6008602052816000526040600020818154811061393557fe5b6000918252602090912001546001600160a01b03169150829050565b6003546001600160a01b031681565b613968614d93565b6139b9576040805162461bcd60e51b815260206004820152601c60248201527f6f6e6c792061646d696e2063616e207365742061727320737065656400000000604482015290519081900360640190fd5b82518251811480156139cb5750815181145b613a065760405162461bcd60e51b8152600401808060200182810382526028815260200180615a2c6028913960400191505060405180910390fd5b60005b81811015611b7a57613a55858281518110613a2057fe5b6020026020010151858381518110613a3457fe5b6020026020010151858481518110613a4857fe5b60200260200101516152af565b600101613a09565b600080546001600160a01b03163314613a8357613a7c60016006614cac565b9050611a18565b6001600160a01b0383166000908152600960205260409020805460ff16613ab857613ab060096007614cac565b915050611a18565b613ac06158a9565b506040805160208101909152838152613ad76158a9565b506040805160208101909152670c7d713b49da00008152613af88183615492565b15613b1357613b0960066008614cac565b9350505050611a18565b8415801590613b9c5750600480546040805163fc57d4df60e01b81526001600160a01b038a8116948201949094529051929091169163fc57d4df91602480820192602092909190829003018186803b158015613b6e57600080fd5b505afa158015613b82573d6000803e3d6000fd5b505050506040513d6020811015613b9857600080fd5b5051155b15613bad57613b09600d6009614cac565b60018301805490869055604080516001600160a01b03891681526020810183905280820188905290517f70483e6592cd5182d45ac970e05bc62cdcc90e9d8ef2c2dbe686cf383bcd7fc59181900360600190a16000979650505050505050565b601260209081526000928352604080842090915290825290205481565b600a54600160a81b900460ff1681565b60055481565b600080613c4e858585614f58565b90508015613c5d579050611ee1565b613c668561495c565b613c708585614af0565b600095945050505050565b60146020526000908152604090205481565b6000808290506000806000836001600160a01b031663c37f68e2336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060806040518083038186803b158015613cee57600080fd5b505afa158015613d02573d6000803e3d6000fd5b505050506040513d6080811015613d1857600080fd5b508051602082015160409092015190945090925090508215613d6b5760405162461bcd60e51b8152600401808060200182810382526025815260200180615a896025913960400191505060405180910390fd5b8015613d8857613d7d600c6002614cac565b945050505050611e0c565b6000613d95873385614f58565b90508015613db657613daa600e600383615499565b95505050505050611e0c565b6001600160a01b0385166000908152600960209081526040808320338452600281019092529091205460ff16613df55760009650505050505050611e0c565b3360009081526002820160209081526040808320805460ff191690556008825291829020805483518184028101840190945280845260609392830182828015613e6757602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613e49575b5050835193945083925060009150505b82811015613ebc57896001600160a01b0316848281518110613e9557fe5b60200260200101516001600160a01b03161415613eb457809150613ebc565b600101613e77565b50818110613ec657fe5b336000908152600860205260409020805481906000198101908110613ee757fe5b9060005260206000200160009054906101000a90046001600160a01b0316818381548110613f1157fe5b600091825260209091200180546001600160a01b0319166001600160a01b03929092169190911790558054613f4a8260001983016158bc565b50604080516001600160a01b038c16815233602082015281517fe699a64c18b07ac5b7301aa273f36a2287239eb9501d81950672794afba29a0d929181900390910190a160009c9b505050505050505050505050565b601b5460ff1681565b6000546001600160a01b031681565b601c6020526000908152604090205481565b60005b835181101561416f576000848281518110613fe457fe5b6020908102919091018101516001600160a01b0381166000908152600990925260409091205490915060ff16614059576040805162461bcd60e51b81526020600482015260156024820152741b585c9ad95d081b5d5cdd081899481b1a5cdd1959605a1b604482015290519081900360640190fd5b6001841515141561411f5761406c6158a9565b6040518060200160405280836001600160a01b031663aa5af0fd6040518163ffffffff1660e01b815260040160206040518083038186803b1580156140b057600080fd5b505afa1580156140c4573d6000803e3d6000fd5b505050506040513d60208110156140da57600080fd5b5051905290506140ea828261427d565b60005b875181101561411c576141148389838151811061410657fe5b602002602001015184614490565b6001016140ed565b50505b60018315151415614166576141338161495c565b60005b86518110156141645761415c8288838151811061414f57fe5b6020026020010151614af0565b600101614136565b505b50600101613fcd565b5060005b8451811015611b7a576141d185828151811061418b57fe5b6020026020010151601460008885815181106141a357fe5b60200260200101516001600160a01b03166001600160a01b0316815260200190815260200160002054615004565b601460008784815181106141e157fe5b6020908102919091018101516001600160a01b0316825281019190915260400160002055600101614173565b6000611ee18383604051806040016040528060118152602001706164646974696f6e206f766572666c6f7760781b8152506154ff565b6000611ee18383604051806040016040528060158152602001747375627472616374696f6e20756e646572666c6f7760581b81525061559a565b6001600160a01b0382166000908152601160209081526040808320601990925282205490916142e86142ad612157565b6040518060400160405280601c81526020017f626c6f636b206e756d62657220657863656564732033322062697473000000008152506155f4565b835490915060009061430a9063ffffffff80851691600160e01b900416614243565b905060008111801561431c5750600083115b15614465576000614391876001600160a01b03166347bd37186040518163ffffffff1660e01b815260040160206040518083038186803b15801561435f57600080fd5b505afa158015614373573d6000803e3d6000fd5b505050506040513d602081101561438957600080fd5b505187615651565b9050600061439f8386614d51565b90506143a96158a9565b600083116143c657604051806020016040528060008152506143d0565b6143d0828461566f565b604080516020810190915288546001600160e01b03168152909150614433906143f990836156a3565b5160408051808201909152601a81527f6e657720696e646578206578636565647320323234206269747300000000000060208201526156c8565b87546001600160e01b0319166001600160e01b039182161716600160e01b63ffffffff8716021787555061215c915050565b801561215c57835463ffffffff8316600160e01b026001600160e01b03909116178455505050505050565b6001600160a01b03838116600090815260116020908152604080832080546013845282852095881685529490925290912080546001600160e01b03909316908190559091801580156144f057506a0c097ce7bc90715b34b9f160241b8210155b1561450657506a0c097ce7bc90715b34b9f160241b5b61450e6158a9565b60405180602001604052806145238585614243565b81525090506000614583886001600160a01b03166395dd9193896040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561435f57600080fd5b90506000614591828461571d565b6001600160a01b038916600090815260146020526040812054919250906145b8908361420d565b6001600160a01b03808b1660008181526014602090815260409182902085905581518781529081018b905281519495509193928e16927f83348684403d6ac51e18549a12cc3a7e465794414a2a124e4f80dfdf1019e53c9281900390910190a350505050505050505050565b60008060006146316158e0565b6001600160a01b0388166000908152600860209081526040808320805482518185028101850190935280835260609383018282801561469957602002820191906000526020600020905b81546001600160a01b0316815260019091019060200180831161467b575b50939450600093505050505b815181101561491d5760008282815181106146bc57fe5b60200260200101519050806001600160a01b031663c37f68e28d6040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060806040518083038186803b15801561471c57600080fd5b505afa158015614730573d6000803e3d6000fd5b505050506040513d608081101561474657600080fd5b508051602082015160408084015160609485015160808b015293890193909352918701919091529350831561478b5750600f9650600095508594506121ac9350505050565b60408051602080820183526001600160a01b0380851660008181526009845285902060010154845260c08a01939093528351808301855260808a0151815260e08a015260048054855163fc57d4df60e01b815291820194909452935192169263fc57d4df9260248083019392829003018186803b15801561480b57600080fd5b505afa15801561481f573d6000803e3d6000fd5b505050506040513d602081101561483557600080fd5b505160a086018190526148585750600d9650600095508594506121ac9350505050565b604080516020810190915260a0860151815261010086015260c085015160e08601516148929161488791615234565b866101000151615234565b6101208601819052604086015186516148ac92919061574b565b8552610100850151606086015160208701516148c992919061574b565b60208601526001600160a01b03818116908c161415614914576148f68561012001518b876020015161574b565b6020860181905261010086015161490e918b9061574b565b60208601525b506001016146a5565b5060208301518351111561494357505060208101519051600094500391508290506121ac565b50508051602090910151600094508493500390506121ac565b6001600160a01b0381166000908152601060209081526040808320601a909252822054909161498c6142ad612157565b83549091506000906149ae9063ffffffff80851691600160e01b900416614243565b90506000811180156149c05750600083115b15614ac6576000856001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b158015614a0057600080fd5b505afa158015614a14573d6000803e3d6000fd5b505050506040513d6020811015614a2a57600080fd5b505190506000614a3a8386614d51565b9050614a446158a9565b60008311614a615760405180602001604052806000815250614a6b565b614a6b828461566f565b604080516020810190915288546001600160e01b03168152909150614a94906143f990836156a3565b87546001600160e01b0319166001600160e01b039182161716600160e01b63ffffffff87160217875550611b7a915050565b8015611b7a57835463ffffffff8316600160e01b026001600160e01b039091161784555050505050565b6001600160a01b03828116600090815260106020908152604080832080546012845282852095871685529490925290912080546001600160e01b0390931690819055909180158015614b5057506a0c097ce7bc90715b34b9f160241b8210155b15614b6657506a0c097ce7bc90715b34b9f160241b5b614b6e6158a9565b6040518060200160405280614b838585614243565b81525090506000866001600160a01b03166370a08231876040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015614be057600080fd5b505afa158015614bf4573d6000803e3d6000fd5b505050506040513d6020811015614c0a57600080fd5b505190506000614c1a828461571d565b6001600160a01b03881660009081526014602052604081205491925090614c41908361420d565b6001600160a01b03808a1660008181526014602090815260409182902085905581518781529081018b905281519495509193928d16927ffe677a2e8dc3132dc6e90589abb43c35d2fb5fe958ba09bef482f5e41bf6506f9281900390910190a3505050505050505050565b60007f45b96fe442630264581b197e84bbada861235052c5a1aadfff9ea4e40a969aa0836011811115614cdb57fe5b836013811115614ce757fe5b604080519283526020830191909152600082820152519081900360600190a1826011811115611ee157fe5b6000806000614d25846000806000614624565b9250925092509193909250565b6000614d3c6158a9565b614d468484615773565b9050611cb181615794565b6000611ee183836040518060400160405280601781526020017f6d756c7469706c69636174696f6e206f766572666c6f770000000000000000008152506157a3565b600080546001600160a01b0316331480614db757506002546001600160a01b031633145b905090565b60005b600d54811015614e4757816001600160a01b0316600d8281548110614de057fe5b6000918252602090912001546001600160a01b03161415614e3f576040805162461bcd60e51b81526020600482015260146024820152731b585c9ad95d08185b1c9958591e48185919195960621b604482015290519081900360640190fd5b600101614dbf565b50600d80546001810182556000919091527fd7b6990105719101dabeb77144f2a3385c8033acd3af97e9423a695e81ad1eb50180546001600160a01b0319166001600160a01b0392909216919091179055565b6000614ea76142ad612157565b6001600160a01b03831660009081526010602090815260408083206011909252909120815492935090916001600160e01b0316614efd5781546001600160e01b0319166a0c097ce7bc90715b34b9f160241b1782555b80546001600160e01b0316614f2b5780546001600160e01b0319166a0c097ce7bc90715b34b9f160241b1781555b805463ffffffff909316600160e01b026001600160e01b0393841681179091558154909216909117905550565b6001600160a01b03831660009081526009602052604081205460ff16614f7f576009612238565b6001600160a01b038085166000908152600960209081526040808320938716835260029093019052205460ff16614fb7576000612238565b600080614fc78587866000614624565b91935090915060009050826011811115614fdd57fe5b14614ff757816011811115614fee57fe5b92505050611ee1565b8015613536576004614fee565b60008061500f612c5c565b604080516370a0823160e01b815230600482015290519192506000916001600160a01b038416916370a08231916024808301926020929190829003018186803b15801561505b57600080fd5b505afa15801561506f573d6000803e3d6000fd5b505050506040513d602081101561508557600080fd5b5051905083158015906150985750808411155b1561513557816001600160a01b031663a9059cbb86866040518363ffffffff1660e01b815260040180836001600160a01b03166001600160a01b0316815260200182815260200192505050602060405180830381600087803b1580156150fd57600080fd5b505af1158015615111573d6000803e3d6000fd5b505050506040513d602081101561512757600080fd5b5060009350611a1892505050565b50919392505050565b6001600160a01b0382166000908152600960205260408120805460ff16615169576009915050611a18565b6001600160a01b038316600090815260028201602052604090205460ff1615156001141561519b576000915050611a18565b6001600160a01b0380841660008181526002840160209081526040808320805460ff19166001908117909155600883528184208054918201815584529282902090920180549489166001600160a01b031990951685179055815193845283019190915280517f3ab23ab0d51cccc0c3085aec51f99228625aa1a922b3a8ca89a26b0f2027a1a59281900390910190a15060009392505050565b61523c6158a9565b6040518060200160405280670de0b6b3a764000061526286600001518660000151614d51565b8161526957fe5b0490529392505050565b61527b6158a9565b60405180602001604052806152a661529f8660000151670de0b6b3a7640000614d51565b8551615819565b90529392505050565b6001600160a01b0383166000908152600960205260409020805460ff1661531d576040805162461bcd60e51b815260206004820152601860248201527f617273206d61726b6574206973206e6f74206c69737465640000000000000000604482015290519081900360640190fd5b6001600160a01b0384166000908152601a60205260409020548314615396576153458461495c565b6001600160a01b0384166000818152601a6020908152604091829020869055815186815291517f8a77ffafc8248b67a55cb39312a8d84f9591f4b2f127d5bcb48d3503e8a0881e9281900390910190a25b6001600160a01b0384166000908152601960205260409020548214612151576153bd6158a9565b6040518060200160405280866001600160a01b031663aa5af0fd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561540157600080fd5b505afa158015615415573d6000803e3d6000fd5b505050506040513d602081101561542b57600080fd5b50519052905061543b858261427d565b6001600160a01b038516600081815260196020908152604091829020869055815186815291517f28296fac6da7787338cb53d8f6b0ade25db8a2c319ced8de99a06c3e050ca71d9281900390910190a25050505050565b5190511090565b60007f45b96fe442630264581b197e84bbada861235052c5a1aadfff9ea4e40a969aa08460118111156154c857fe5b8460138111156154d457fe5b604080519283526020830191909152818101859052519081900360600190a1836011811115611cb157fe5b600083830182858210156155915760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561555657818101518382015260200161553e565b50505050905090810190601f1680156155835780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b50949350505050565b600081848411156155ec5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561555657818101518382015260200161553e565b505050900390565b600081600160201b84106156495760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561555657818101518382015260200161553e565b509192915050565b6000611ee161566884670de0b6b3a7640000614d51565b8351615819565b6156776158a9565b60405180602001604052806152a661569d866a0c097ce7bc90715b34b9f160241b614d51565b85615819565b6156ab6158a9565b60405180602001604052806152a68560000151856000015161420d565b600081600160e01b84106156495760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561555657818101518382015260200161553e565b60006a0c097ce7bc90715b34b9f160241b61573c848460000151614d51565b8161574357fe5b049392505050565b60006157556158a9565b61575f8585615773565b905061263861576d82615794565b8461420d565b61577b6158a9565b60405180602001604052806152a6856000015185614d51565b51670de0b6b3a7640000900490565b60008315806157b0575082155b156157bd57506000611ee1565b838302838582816157ca57fe5b041483906155915760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561555657818101518382015260200161553e565b6000611ee183836040518060400160405280600e81526020016d646976696465206279207a65726f60901b815250600081836158965760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561555657818101518382015260200161553e565b508284816158a057fe5b04949350505050565b6040518060200160405280600081525090565b815481835581811115611bed57600083815260209020611bed91810190830161594a565b60405180610140016040528060008152602001600081526020016000815260200160008152602001600081526020016000815260200161591e6158a9565b815260200161592b6158a9565b81526020016159386158a9565b81526020016159456158a9565b905290565b61215991905b808211156159645760008155600101615950565b509056fe63616e6e6f742070617573652061206d61726b65742074686174206973206e6f74206c697374656443616e206e6f74207265706179206d6f7265207468616e2074686520746f74616c20626f72726f77416c72656164792065786563757465642074686973206f6e652d6f66662066756e6374696f6e6f6e6c7920706175736520677561726469616e20616e642061646d696e2063616e2070617573656f6e6c792061646d696e2063616e2073657420626f72726f772063617020677561726469616e436f6d7074726f6c6c65723a3a5f73657441727353706565647320696e76616c696420696e7075746f6e6c792061646d696e206f7220626f72726f772063617020677561726469616e2063616e2073657420626f72726f772063617073657869744d61726b65743a206765744163636f756e74536e617073686f74206661696c65644f6e6c792061646d696e2063616e2063616c6c20746869732066756e6374696f6e6f6e6c7920756e6974726f6c6c65722061646d696e2063616e206368616e676520627261696e73a265627a7a7231582011d51fbd4e0a03c138e2cbdbd71d79a896490f2a738a9e23bbff09fdce256dbb64736f6c63430005110032

Deployed ByteCode Sourcemap

136670:63204:0:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;136670:63204:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;192:41;;;:::i;:::-;;;;;;;;;;;;;;;;;;139826:46;;;:::i;:::-;;;;-1:-1:-1;;;;;139826:46:0;;;;;;;;;;;;;;116902:52;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;116902:52:0;-1:-1:-1;;;;;116902:52:0;;:::i;:::-;;;;;;;;;;;;;;;;182371:2161;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;182371:2161:0;;;;;;;;-1:-1:-1;;;5:28;;2:2;;;46:1;43;36:12;2:2;182371:2161:0;;35:9:-1;28:4;12:14;8:25;5:40;2:2;;;58:1;55;48:12;2:2;182371:2161:0;;;;;;101:9:-1;95:2;81:12;77:21;67:8;63:36;60:51;-1:-1;;;25:12;22:29;11:108;8:2;;;132:1;129;122:12;8:2;182371:2161:0;;;;;;;;;;;-1:-1:-1;;;5:28;;2:2;;;46:1;43;36:12;2:2;182371:2161:0;;35:9:-1;28:4;12:14;8:25;5:40;2:2;;;58:1;55;48:12;2:2;182371:2161:0;;;;;;101:9:-1;95:2;81:12;77:21;67:8;63:36;60:51;-1:-1;;;25:12;22:29;11:108;8:2;;;132:1;129;122:12;8:2;-1:-1;182371:2161:0;;-1:-1:-1;182371:2161:0;-1:-1:-1;182371:2161:0;:::i;:::-;;193768:95;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;193768:95:0;-1:-1:-1;;;;;193768:95:0;;:::i;180781:509::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;;180781:509:0;;;;;;;;;;:::i;182061:234::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;182061:234:0;-1:-1:-1;;;;;182061:234:0;;:::i;154507:458::-;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;-1:-1;;;;;;154507:458:0;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;116535:32::-;;;:::i;:::-;;;;-1:-1:-1;;;;;116535:32:0;;;;;;;;;;;;;;194076:207;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;194076:207:0;;;;;;;;;;;;;;;-1:-1:-1;;;5:28;;2:2;;;46:1;43;36:12;2:2;194076:207:0;;35:9:-1;28:4;12:14;8:25;5:40;2:2;;;58:1;55;48:12;2:2;194076:207:0;;;;;;101:9:-1;95:2;81:12;77:21;67:8;63:36;60:51;-1:-1;;;25:12;22:29;11:108;8:2;;;132:1;129;122:12;8:2;194076:207:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;30:3:-1;22:6;14;1:33;99:1;81:16;;74:27;;;;-1:-1;194076:207:0;;-1:-1:-1;194076:207:0;;-1:-1:-1;;;;;194076:207:0:i;153548:637::-;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;-1:-1;;;;;;153548:637:0;;;;;;;;;;;;;;;;;;;;;;:::i;114666:28::-;;;:::i;112441:27::-;;;:::i;181684:369::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;181684:369:0;;;;:::i;115635:56::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;115635:56:0;-1:-1:-1;;;;;115635:56:0;;:::i;:::-;;;;-1:-1:-1;;;;;115635:56:0;;;;;;;;;;;;;;;;;;;;;;171888:423;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;171888:423:0;;:::i;178860:557::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;178860:557:0;-1:-1:-1;;;;;178860:557:0;;:::i;180270:503::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;;180270:503:0;;;;;;;;;;:::i;114701:31::-;;;:::i;115524:41::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;115524:41:0;-1:-1:-1;;;;;115524:41:0;;:::i;147135:362::-;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;-1:-1;;;;;;147135:362:0;;;;;;;;;;;;;;;;;;;;;;:::i;199544:91::-;;;:::i;157372:546::-;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;-1:-1;;;;;;157372:546:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;116714:42::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;116714:42:0;-1:-1:-1;;;;;116714:42:0;;:::i;113148:40::-;;;:::i;164563:408::-;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;-1:-1;;;;;;164563:408:0;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;146209:594;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;;146209:594:0;;;;;;;;;;;;;;;;;:::i;174625:742::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;174625:742:0;;:::i;149612:349::-;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;-1:-1;;;;;;149612:349:0;;;;;;;;;;;;;;;;;;;;;;:::i;115310:26::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;115310:26:0;;:::i;171048:572::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;171048:572:0;-1:-1:-1;;;;;171048:572:0;;:::i;152729:322::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;;152729:322:0;;;;;;;;;;;;;;;;;:::i;163184:268::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;163184:268:0;-1:-1:-1;;;;;163184:268:0;;:::i;179655:607::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;179655:607:0;-1:-1:-1;;;;;179655:607:0;;:::i;155419:1479::-;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;-1:-1;;;;;;155419:1479:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;178086:604::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;178086:604:0;;;;;;;;-1:-1:-1;;;5:28;;2:2;;;46:1;43;36:12;2:2;178086:604:0;;35:9:-1;28:4;12:14;8:25;5:40;2:2;;;58:1;55;48:12;2:2;178086:604:0;;;;;;101:9:-1;95:2;81:12;77:21;67:8;63:36;60:51;-1:-1;;;25:12;22:29;11:108;8:2;;;132:1;129;122:12;8:2;178086:604:0;;;;;;;;;;;-1:-1:-1;;;5:28;;2:2;;;46:1;43;36:12;2:2;178086:604:0;;35:9:-1;28:4;12:14;8:25;5:40;2:2;;;58:1;55;48:12;2:2;178086:604:0;;;;;;101:9:-1;95:2;81:12;77:21;67:8;63:36;60:51;-1:-1;;;25:12;22:29;11:108;8:2;;;132:1;129;122:12;8:2;-1:-1;178086:604:0;;-1:-1:-1;178086:604:0;-1:-1:-1;178086:604:0;:::i;117270:47::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;117270:47:0;-1:-1:-1;;;;;117270:47:0;;:::i;161839:345::-;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;-1:-1;;;;;;161839:345:0;;;;;;;;;;;;;;;;;;;;;;:::i;114915:52::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;114915:52:0;-1:-1:-1;;;;;114915:52:0;;:::i;159811:475::-;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;-1:-1;;;;;;159811:475:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;114858:50::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;114858:50:0;-1:-1:-1;;;;;114858:50:0;;:::i;193042:582::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;193042:582:0;-1:-1:-1;;;;;193042:582:0;;:::i;115420:19::-;;;:::i;112849:25::-;;;:::i;114779:34::-;;;:::i;114346:41::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;114346:41:0;-1:-1:-1;;;;;114346:41:0;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;181298:378;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;181298:378:0;;;;:::i;141048:163::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;;141048:163:0;;;;;;;;;;:::i;199250:286::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;199250:286:0;-1:-1:-1;;;;;199250:286:0;;:::i;113318:21::-;;;:::i;198081:636::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;;198081:636:0;;;;;;;;:::i;117427:47::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;117427:47:0;-1:-1:-1;;;;;117427:47:0;;:::i;199748:123::-;;;:::i;175694:777::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;175694:777:0;-1:-1:-1;;;;;175694:777:0;;:::i;115761:56::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;115761:56:0;-1:-1:-1;;;;;115761:56:0;;:::i;140597:174::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;140597:174:0;-1:-1:-1;;;;;140597:174:0;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:100:-1;33:3;30:1;27:10;8:100;;;90:11;;;84:18;71:11;;;64:39;52:2;45:10;8:100;;;12:14;140597:174:0;;;;;;;;;;;;;;;;;114820:31;;;:::i;198908:99::-;;;:::i;112537:40::-;;;:::i;160753:761::-;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;-1:-1;;;;;;160753:761:0;;;;;;;;;;;;;;;;;;;;;;:::i;117048:52::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;117048:52:0;-1:-1:-1;;;;;117048:52:0;;:::i;196727:309::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;;196727:309:0;;;;;;;;:::i;141477:379::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;141477:379:0;;;;;;;;-1:-1:-1;;;5:28;;2:2;;;46:1;43;36:12;2:2;141477:379:0;;35:9:-1;28:4;12:14;8:25;5:40;2:2;;;58:1;55;48:12;2:2;141477:379:0;;;;;;101:9:-1;95:2;81:12;77:21;67:8;63:36;60:51;-1:-1;;;25:12;22:29;11:108;8:2;;;132:1;129;122:12;8:2;141477:379:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;30:3:-1;22:6;14;1:33;99:1;81:16;;74:27;;;;-1:-1;141477:379:0;;-1:-1:-1;141477:379:0;;-1:-1:-1;;;;;141477:379:0:i;169229:1554::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;;169229:1554:0;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;116121:68;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;;116121:68:0;;;;;;;;;;:::i;158381:969::-;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;-1:-1;;;;;;158381:969:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;150402:2020::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;;150402:2020:0;;;;;;;;;;;;;;;;;:::i;113446:49::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;;113446:49:0;;;;;;;;:::i;112647:47::-;;;:::i;197368:509::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;197368:509:0;;;;;;;;-1:-1:-1;;;5:28;;2:2;;;46:1;43;36:12;2:2;197368:509:0;;35:9:-1;28:4;12:14;8:25;5:40;2:2;;;58:1;55;48:12;2:2;197368:509:0;;;;;;101:9:-1;95:2;81:12;77:21;67:8;63:36;60:51;-1:-1;;;25:12;22:29;11:108;8:2;;;132:1;129;122:12;8:2;197368:509:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;30:3:-1;22:6;14;1:33;99:1;81:16;;74:27;;;;-1:-1;197368:509:0;;;;;;;;-1:-1:-1;197368:509:0;;-1:-1:-1;;;;;5:28;;2:2;;;46:1;43;36:12;2:2;197368:509:0;;35:9:-1;28:4;12:14;8:25;5:40;2:2;;;58:1;55;48:12;2:2;197368:509:0;;;;;;101:9:-1;95:2;81:12;77:21;67:8;63:36;60:51;-1:-1;;;25:12;22:29;11:108;8:2;;;132:1;129;122:12;8:2;197368:509:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;30:3:-1;22:6;14;1:33;99:1;81:16;;74:27;;;;-1:-1;197368:509:0;;;;;;;;-1:-1:-1;197368:509:0;;-1:-1:-1;;;;;5:28;;2:2;;;46:1;43;36:12;2:2;197368:509:0;;35:9:-1;28:4;12:14;8:25;5:40;2:2;;;58:1;55;48:12;2:2;197368:509:0;;;;;;101:9:-1;95:2;81:12;77:21;67:8;63:36;60:51;-1:-1;;;25:12;22:29;11:108;8:2;;;132:1;129;122:12;8:2;197368:509:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;30:3:-1;22:6;14;1:33;99:1;81:16;;74:27;;;;-1:-1;197368:509:0;;-1:-1:-1;197368:509:0;;-1:-1:-1;;;;;197368:509:0:i;172685:1639::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;;172685:1639:0;;;;;;;;:::i;115935:68::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;;115935:68:0;;;;;;;;;;:::i;114739:33::-;;;:::i;112996:31::-;;;:::i;147948:443::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;;147948:443:0;;;;;;;;;;;;;;;;;:::i;116268:42::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;116268:42:0;-1:-1:-1;;;;;116268:42:0;;:::i;143553:2177::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;143553:2177:0;-1:-1:-1;;;;;143553:2177:0;;:::i;117657:33::-;;;:::i;112340:20::-;;;:::i;117800:45::-;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;117800:45:0;-1:-1:-1;;;;;117800:45:0;;:::i;194621:1090::-;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;194621:1090:0;;;;;;;;-1:-1:-1;;;5:28;;2:2;;;46:1;43;36:12;2:2;194621:1090:0;;35:9:-1;28:4;12:14;8:25;5:40;2:2;;;58:1;55;48:12;2:2;194621:1090:0;;;;;;101:9:-1;95:2;81:12;77:21;67:8;63:36;60:51;-1:-1;;;25:12;22:29;11:108;8:2;;;132:1;129;122:12;8:2;194621:1090:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;30:3:-1;22:6;14;1:33;99:1;81:16;;74:27;;;;-1:-1;194621:1090:0;;;;;;;;-1:-1:-1;194621:1090:0;;-1:-1:-1;;;;;5:28;;2:2;;;46:1;43;36:12;2:2;194621:1090:0;;35:9:-1;28:4;12:14;8:25;5:40;2:2;;;58:1;55;48:12;2:2;194621:1090:0;;;;;;101:9:-1;95:2;81:12;77:21;67:8;63:36;60:51;-1:-1;;;25:12;22:29;11:108;8:2;;;132:1;129;122:12;8:2;194621:1090:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;30:3:-1;22:6;14;1:33;99:1;81:16;;74:27;;;;-1:-1;194621:1090:0;;-1:-1:-1;;;;194621:1090:0;;;;;-1:-1:-1;194621:1090:0;;;;;;:::i;192:41::-;229:4;192:41;:::o;139826:46::-;-1:-1:-1;;;139826:46:0;:::o;116902:52::-;;;;;;;;;;;;;:::o;182371:2161::-;182496:5;;-1:-1:-1;;;;;182496:5:0;182482:10;:19;182474:65;;;;-1:-1:-1;;;182474:65:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;182603:21;;;;182602:22;182594:73;;;;-1:-1:-1;;;182594:73:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;182736:38;;;182728:64;;;;;-1:-1:-1;;;182728:64:0;;;;;;;;;;;;-1:-1:-1;;;182728:64:0;;;;;;;;;;;;;;;182832:12;;;;;182992:1435;183009:24;;;182992:1435;;;183062:13;;183076:1;183062:16;;;;;;;;;;;;;-1:-1:-1;;;;;183062:16:0;183055:23;;183110:10;:16;183121:4;-1:-1:-1;;;;;183110:16:0;-1:-1:-1;;;;;183110:16:0;;;;;;;;;;;;;183093:33;;183162:7;;183170:1;183162:10;;;;;;;;;;;;;183143:29;;183400:14;183381:16;:33;183377:647;;;-1:-1:-1;;;;;183654:19:0;;183496:22;183654:19;;;:13;:19;;;;;;183521:33;;;;183713:38;183654:19;183521:33;183713:4;:38::i;:::-;-1:-1:-1;;;;;183837:19:0;;;;;;:13;:19;;;;;;;;;:35;;;183898:56;;;;;;;;;;;;;183692:59;;-1:-1:-1;183837:19:0;;183898:56;;;;;;;;;;183994:14;183975:33;;183377:647;;;;184056:20;;184052:364;;184284:38;184289:14;184305:16;184284:4;:38::i;:::-;-1:-1:-1;;;;;184252:16:0;;;;;;:10;:16;;;;;;;;;:70;;;184348:52;;;;;;;;;;;;;184271:51;;-1:-1:-1;184252:16:0;;184348:52;;;;;;;;;;184052:364;183035:3;;182992:1435;;;-1:-1:-1;;184439:21:0;:28;;-1:-1:-1;;184439:28:0;184463:4;184439:28;;;-1:-1:-1;;;;;;;182371:2161:0:o;193768:95::-;193827:28;193836:6;193844:10;193827:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;193827:28:0;;;;;;;;;;;;;;;;;;;;;:8;:28::i;:::-;193768:95;:::o;180781:509::-;-1:-1:-1;;;;;180875:24:0;;180850:4;180875:24;;;:7;:24;;;;;:33;;;180867:86;;;;-1:-1:-1;;;180867:86:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;180986:13;;-1:-1:-1;;;;;180986:13:0;180972:10;:27;;:50;;-1:-1:-1;181017:5:0;;-1:-1:-1;;;;;181017:5:0;181003:10;:19;180972:50;180964:102;;;;-1:-1:-1;;;180964:102:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;181099:5;;-1:-1:-1;;;;;181099:5:0;181085:10;:19;;:36;;-1:-1:-1;181117:4:0;181108:13;;;;181085:36;181077:71;;;;;-1:-1:-1;;;181077:71:0;;;;;;;;;;;;-1:-1:-1;;;181077:71:0;;;;;;;;;;;;;;;-1:-1:-1;;;;;181161:37:0;;;;;;:20;:37;;;;;;;;;:45;;;;;-1:-1:-1;;181161:45:0;;;;;;;;181222:37;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;181222:37:0;;;;;;;;;;;;;;-1:-1:-1;181277:5:0;180781:509;;;;;:::o;182061:234::-;182141:10;-1:-1:-1;;;;;182141:16:0;;:18;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;182141:18:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;182141:18:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;182141:18:0;-1:-1:-1;;;;;182127:32:0;:10;:32;182119:84;;;;-1:-1:-1;;;182119:84:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;182222:10;-1:-1:-1;;;;;182222:32:0;;:34;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;182222:34:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;182222:34:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;182222:34:0;:39;182214:73;;;;;-1:-1:-1;;;182214:73:0;;;;;;;;;;;;-1:-1:-1;;;182214:73:0;;;;;;;;;;;;;;154507:458;;;;;;:::o;116535:32::-;;;-1:-1:-1;;;;;116535:32:0;;:::o;194076:207::-;194180:16;;;194194:1;194180:16;;;;;;;;;194153:24;;194180:16;;;;;;105:10:-1;194180:16:0;88:34:-1;136:17;;-1:-1;194180:16:0;194153:43;;194220:6;194207:7;194215:1;194207:10;;;;;;;;;;;;;:19;-1:-1:-1;;;;;194207:19:0;;;-1:-1:-1;;;;;194207:19:0;;;;;194237:38;194246:7;194255;194264:4;194270;194237:8;:38::i;:::-;194076:207;;;:::o;153548:637::-;-1:-1:-1;;;;;153814:15:0;;153698:4;153814:15;;;:7;:15;;;;;:24;;;153809:94;;-1:-1:-1;153867:23:0;153855:36;;153809:94;153952:22;;:::i;:::-;153977:45;;;;;;;;153999:6;-1:-1:-1;;;;;153992:26:0;;:28;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;153992:28:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;153992:28:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;153992:28:0;153977:45;;153952:70;-1:-1:-1;154033:41:0;154054:6;153952:70;154033:20;:41::i;:::-;154085:52;154107:6;154115:8;154125:11;154085:21;:52::i;:::-;154162:14;154150:27;;;153548:637;;;;;;;:::o;114666:28::-;;;-1:-1:-1;;;;;114666:28:0;;:::o;112441:27::-;;;-1:-1:-1;;;;;112441:27:0;;:::o;181684:369::-;181776:13;;181737:4;;-1:-1:-1;;;;;181776:13:0;181762:10;:27;;:50;;-1:-1:-1;181807:5:0;;-1:-1:-1;;;;;181807:5:0;181793:10;:19;181762:50;181754:102;;;;-1:-1:-1;;;181754:102:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;181889:5;;-1:-1:-1;;;;;181889:5:0;181875:10;:19;;:36;;-1:-1:-1;181907:4:0;181898:13;;;;181875:36;181867:71;;;;;-1:-1:-1;;;181867:71:0;;;;;;;;;;;;-1:-1:-1;;;181867:71:0;;;;;;;;;;;;;;;181951:19;:27;;;;;-1:-1:-1;;;181951:27:0;;-1:-1:-1;;;;181951:27:0;;;;;;;;;;181994:28;;;;;;;;;;;;;;;;;;-1:-1:-1;;;181994:28:0;;;;;;;;;;;;;;-1:-1:-1;182040:5:0;181684:369;;;;:::o;115635:56::-;;;;;;;;;;;;-1:-1:-1;;;;;115635:56:0;;;-1:-1:-1;;;115635:56:0;;;;;:::o;171888:423::-;171960:4;172030:5;;-1:-1:-1;;;;;172030:5:0;172016:10;:19;172008:63;;;;;-1:-1:-1;;;172008:63:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;172114:19;;;172144:44;;;;172204:59;;;;;;;;;;;;;;;;;;;;;;;;;172288:14;172283:20;172276:27;171888:423;-1:-1:-1;;;171888:423:0:o;178860:557::-;178963:5;;-1:-1:-1;;;;;178963:5:0;178949:10;:19;178941:70;;;;-1:-1:-1;;;178941:70:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;179107:17;;;-1:-1:-1;;;;;179205:40:0;;;-1:-1:-1;;;;;;179205:40:0;;;;;;;179345:64;;;179107:17;;;;179345:64;;;;;;;;;;;;;;;;;;;;;;;178860:557;;:::o;180270:503::-;-1:-1:-1;;;;;180362:24:0;;180337:4;180362:24;;;:7;:24;;;;;:33;;;180354:86;;;;-1:-1:-1;;;180354:86:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;180473:13;;-1:-1:-1;;;;;180473:13:0;180459:10;:27;;:50;;-1:-1:-1;180504:5:0;;-1:-1:-1;;;;;180504:5:0;180490:10;:19;180459:50;180451:102;;;;-1:-1:-1;;;180451:102:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;180586:5;;-1:-1:-1;;;;;180586:5:0;180572:10;:19;;:36;;-1:-1:-1;180604:4:0;180595:13;;;;180572:36;180564:71;;;;;-1:-1:-1;;;180564:71:0;;;;;;;;;;;;-1:-1:-1;;;180564:71:0;;;;;;;;;;;;;;;-1:-1:-1;;;;;180648:35:0;;;;;;:18;:35;;;;;;;;;:43;;;;;-1:-1:-1;;180648:43:0;;;;;;;;180707:35;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;180707:35:0;;;;;;;;;;;;;;-1:-1:-1;180760:5:0;180270:503;-1:-1:-1;180270:503:0:o;114701:31::-;;;-1:-1:-1;;;114701:31:0;;;;;:::o;115524:41::-;;;;;;;;;;;;;:::o;147135:362::-;;;;;:::o;199544:91::-;199615:12;199544:91;;:::o;157372:546::-;;;;;;;:::o;116714:42::-;;;;;;;;;;;;;:::o;113148:40::-;;;;:::o;164563:408::-;164739:4;164745;164751;164769:9;164780:14;164796;164814:98;164854:7;164870:12;164885;164899;164814:39;:98::i;:::-;164768:144;;;;;;164936:3;164931:9;;;;;;;;164923:40;-1:-1:-1;164942:9:0;;-1:-1:-1;164953:9:0;-1:-1:-1;;164563:408:0;;;;;;;;;:::o;146209:594::-;-1:-1:-1;;;;;146403:26:0;;146297:4;146403:26;;;:18;:26;;;;;;;;146402:27;146394:54;;;;;-1:-1:-1;;;146394:54:0;;;;;;;;;;;;-1:-1:-1;;;146394:54:0;;;;;;;;;;;;;;;-1:-1:-1;;;;;146541:15:0;;;;;;:7;:15;;;;;:24;;;146536:94;;146594:23;146589:29;146582:36;;;;146536:94;146679:28;146700:6;146679:20;:28::i;:::-;146718:37;146740:6;146748;146718:21;:37::i;:::-;146780:14;146768:27;146209:594;-1:-1:-1;;;;146209:594:0:o;174625:742::-;174715:4;174784:5;;-1:-1:-1;;;;;174784:5:0;174770:10;:19;174766:134;;174813:75;174818:18;174838:49;174813:4;:75::i;:::-;174806:82;;;;174766:134;174997:28;;;175093:62;;;;175230:89;;;;;;;;;;;;;;;;;;;;;;;;;175344:14;175339:20;;149612:349;149861:17;;:37;;;;;149897:1;149882:12;:16;149861:37;149857:97;;;149915:27;;;-1:-1:-1;;;149915:27:0;;;;;;;;;;;;-1:-1:-1;;;149915:27:0;;;;;;;;;;;;;;115310:26;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;115310:26:0;;-1:-1:-1;115310:26:0;:::o;171048:572::-;171112:4;171181:5;;-1:-1:-1;;;;;171181:5:0;171167:10;:19;171163:125;;171210:66;171215:18;171235:40;171210:4;:66::i;171163:125::-;171377:6;;;-1:-1:-1;;;;;171446:18:0;;;-1:-1:-1;;;;;;171446:18:0;;;;;;;171536:36;;;171377:6;;;;171536:36;;;;;;;;;;;;;;;;;;;;;;;171597:14;171592:20;;152729:322;152985:59;;163184:268;163251:4;163257;163263;163281:9;163292:14;163308;163326:65;163366:7;163382:1;163386;163389;163326:39;:65::i;:::-;163280:111;;;;;;163417:3;163412:9;;;;;;;;163404:40;163423:9;;-1:-1:-1;163423:9:0;-1:-1:-1;163184:268:0;-1:-1:-1;;;163184:268:0:o;179655:607::-;179724:4;179759:5;;-1:-1:-1;;;;;179759:5:0;179745:10;:19;179741:127;;179788:68;179793:18;179813:42;179788:4;:68::i;179741:127::-;179959:13;;;-1:-1:-1;;;;;180045:32:0;;;-1:-1:-1;;;;;;180045:32:0;;;;;;;180165:49;;;179959:13;;;180165:49;;;180200:13;;;;180165:49;;;;;;;;;;;;;;;;180239:14;180234:20;;155419:1479;-1:-1:-1;;;;;155701:23:0;;155621:4;155701:23;;;:7;:23;;;;;:32;;;155700:33;;:72;;-1:-1:-1;;;;;;155738:25:0;;;;;;:7;:25;;;;;:34;;;155737:35;155700:72;155696:141;;;155801:23;155796:29;155789:36;;;;155696:141;155849:18;155877:14;-1:-1:-1;;;;;155870:42:0;;155913:8;155870:52;;;;;;;;;;;;;-1:-1:-1;;;;;155870:52:0;-1:-1:-1;;;;;155870:52:0;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;155870:52:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;155870:52:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;155870:52:0;;-1:-1:-1;156014:36:0;156034:14;156014:12;:36::i;:::-;156010:843;;;156092:11;156075:13;:28;;156067:81;;;;-1:-1:-1;;;156067:81:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;156010:843;;;156262:9;156275:14;156293:37;156321:8;156293:27;:37::i;:::-;156261:69;;-1:-1:-1;156261:69:0;;-1:-1:-1;156356:14:0;;-1:-1:-1;156349:3:0;:21;;;;;;;;;156345:78;;156403:3;156398:9;;;;;;;;156391:16;;;;;;;156345:78;156443:14;156439:96;;156490:28;156485:34;;156439:96;156644:13;156660:71;156679:36;;;;;;;;156694:19;;156679:36;;;156717:13;156660:18;:71::i;:::-;156644:87;;156764:8;156750:11;:22;156746:96;;;156805:20;156793:33;;;;;;;;156746:96;156010:843;;;;156875:14;156863:27;;;155419:1479;;;;;;;;:::o;178086:604::-;178213:5;;-1:-1:-1;;;;;178213:5:0;178199:10;:19;;:54;;-1:-1:-1;178236:17:0;;-1:-1:-1;;;;;178236:17:0;178222:10;:31;178199:54;178191:120;;;;-1:-1:-1;;;178191:120:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;178343:7;178389:13;178430:15;;;;;:46;;;178463:13;178449:10;:27;178430:46;178422:72;;;;;-1:-1:-1;;;178422:72:0;;;;;;;;;;;;-1:-1:-1;;;178422:72:0;;;;;;;;;;;;;;;178511:6;178507:176;178527:10;178523:1;:14;178507:176;;;178593:13;;178607:1;178593:16;;;;;;;;;;;;;178559:10;:31;178578:7;;178586:1;178578:10;;;;;;;;;;;;;-1:-1:-1;;;;;178578:10:0;-1:-1:-1;;;;;178559:31:0;-1:-1:-1;;;;;178559:31:0;;;;;;;;;;;;:50;;;;178642:7;;178650:1;178642:10;;;;;;;;;;;;;-1:-1:-1;;;;;178642:10:0;-1:-1:-1;;;;;178629:42:0;;178654:13;;178668:1;178654:16;;;;;;;;;;;;;178629:42;;;;;;;;;;;;;;;;;;178539:3;;178507:176;;;;178086:604;;;;;;:::o;117270:47::-;;;;;;;;;;;;;:::o;114915:52::-;;;;;;;;;;;;;;;:::o;114858:50::-;;;;;;;;;;;;;;;:::o;193042:582::-;-1:-1:-1;;;;;193131:33:0;;193115:13;193131:33;;;:20;:33;;;;;;;193194:16;:14;:16::i;:::-;-1:-1:-1;;;;;193258:33:0;;193221:16;193258:33;;;:20;:33;;;;;;193175:35;;-1:-1:-1;193221:16:0;193240:52;;193175:35;;193240:4;:52::i;:::-;193221:71;;193321:1;193307:11;:15;:31;;;;;193337:1;193326:8;:12;193307:31;193303:314;;;193355:15;193373:27;193378:11;193391:8;193373:4;:27::i;:::-;-1:-1:-1;;;;;193446:23:0;;193415;193446;;;:10;:23;;;;;;193355:45;;-1:-1:-1;193415:23:0;193441:41;;193355:45;193441:4;:41::i;:::-;-1:-1:-1;;;;;193499:23:0;;;;;;:10;:23;;;;;;;;:44;;;;193558:20;:33;;;:47;;;-1:-1:-1;;193042:582:0;;;;:::o;115420:19::-;;;;:::o;112849:25::-;;;-1:-1:-1;;;;;112849:25:0;;:::o;114779:34::-;;;-1:-1:-1;;;114779:34:0;;;;;:::o;114346:41::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;181298:378::-;181393:13;;181354:4;;-1:-1:-1;;;;;181393:13:0;181379:10;:27;;:50;;-1:-1:-1;181424:5:0;;-1:-1:-1;;;;;181424:5:0;181410:10;:19;181379:50;181371:102;;;;-1:-1:-1;;;181371:102:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;181506:5;;-1:-1:-1;;;;;181506:5:0;181492:10;:19;;:36;;-1:-1:-1;181524:4:0;181515:13;;;;181492:36;181484:71;;;;;-1:-1:-1;;;181484:71:0;;;;;;;;;;;;-1:-1:-1;;;181484:71:0;;;;;;;;;;;;;;;181568:22;:30;;;;;-1:-1:-1;;;181568:30:0;;-1:-1:-1;;;;181568:30:0;;;;;;;;;;181614:31;;;;;;;;;;;;;;;;;;-1:-1:-1;;;181614:31:0;;;;;;;;;;;;;;-1:-1:-1;181663:5:0;181298:378::o;141048:163::-;-1:-1:-1;;;;;141152:24:0;;;141128:4;141152:24;;;:7;:24;;;;;;;;:51;;;;;:42;;;;:51;;;;;;141048:163;;;;:::o;199250:286::-;-1:-1:-1;;;;;199345:24:0;;199308:4;199345:24;;;:7;:24;;;;;:49;;;:54;:117;;;;-1:-1:-1;;;;;;199417:37:0;;;;;;:20;:37;;;;;;;;:45;;:37;:45;199345:117;:173;;;;;199480:6;-1:-1:-1;;;;;199480:28:0;;:30;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;199480:30:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;199480:30:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;199480:30:0;199514:4;199480:38;199325:193;199250:286;-1:-1:-1;;199250:286:0:o;113318:21::-;;;;:::o;198081:636::-;198176:21;:19;:21::i;:::-;198168:62;;;;;-1:-1:-1;;;198168:62:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;198337:37;198362:11;198337:24;:37::i;:::-;198389:13;198385:203;;-1:-1:-1;;;;;198458:33:0;;;;;;:20;:33;;;;;198451:40;198385:203;;;198560:16;:14;:16::i;:::-;-1:-1:-1;;;;;198524:33:0;;;;;;:20;:33;;;;;:52;198385:203;-1:-1:-1;;;;;198598:33:0;;;;;;:20;:33;;;;;;;;;:44;;;198660:49;;;;;;;;;;;;;;;;;198081:636;;:::o;117427:47::-;;;;;;;;;;;;;:::o;199748:123::-;199821:42;199748:123;:::o;175694:777::-;175751:4;175786:5;;-1:-1:-1;;;;;175786:5:0;175772:10;:19;175768:123;;175815:64;175820:18;175840:38;175815:4;:64::i;175768:123::-;-1:-1:-1;;;;;175907:24:0;;;;;;:7;:24;;;;;:33;;;175903:141;;;175964:68;175969:27;175998:33;175964:4;:68::i;175903:141::-;176056:6;-1:-1:-1;;;;;176056:15:0;;:17;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;176056:17:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;176056:17:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;176222:70:0;;;;;;;;176240:4;176222:70;;;-1:-1:-1;176056:17:0;176222:70;;;;;;;;;;;;-1:-1:-1;;;;;176195:24:0;;;;:7;:24;;;;;;;:97;;;;;;;-1:-1:-1;;176195:97:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;176305:35;176211:6;176305:18;:35::i;:::-;176351:34;176377:6;176351:17;:34::i;:::-;176403:20;;;-1:-1:-1;;;;;176403:20:0;;;;;;;;;;;;;;;176448:14;176443:20;;115761:56;;;;;;;;;;;;-1:-1:-1;;;;;115761:56:0;;;-1:-1:-1;;;115761:56:0;;;;;:::o;140597:174::-;140658:15;140686:24;140713:13;:22;140727:7;-1:-1:-1;;;;;140713:22:0;-1:-1:-1;;;;;140713:22:0;;;;;;;;;;;;140686:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;140686:49:0;;;;;;;;;;;;;;;;-1:-1:-1;140686:49:0;;140597:174;-1:-1:-1;;;;;;;140597:174:0:o;114820:31::-;;;-1:-1:-1;;;114820:31:0;;;;;:::o;198908:99::-;198954:15;198989:10;198982:17;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;198982:17:0;;;;;;;;;;;;;;;;;;;;;;;198908:99;:::o;112537:40::-;;;-1:-1:-1;;;;;112537:40:0;;:::o;160753:761::-;160965:22;;160859:4;;-1:-1:-1;;;160965:22:0;;;;160964:23;160956:54;;;;;-1:-1:-1;;;160956:54:0;;;;;;;;;;;;-1:-1:-1;;;160956:54:0;;;;;;;;;;;;;;;161145:12;161160:50;161182:6;161190:3;161195:14;161160:21;:50::i;:::-;161145:65;-1:-1:-1;161225:31:0;;161221:78;;161280:7;-1:-1:-1;161273:14:0;;161221:78;161348:28;161369:6;161348:20;:28::i;:::-;161387:34;161409:6;161417:3;161387:21;:34::i;:::-;161432;161454:6;161462:3;161432:21;:34::i;117048:52::-;;;;;;;;;;;;;:::o;196727:309::-;196804:21;:19;:21::i;:::-;196796:58;;;;;-1:-1:-1;;;196796:58:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;196865:15;196883:35;196900:9;196911:6;196883:16;:35::i;:::-;196865:53;-1:-1:-1;196937:15:0;;196929:54;;;;;-1:-1:-1;;;196929:54:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;196999:29;;;-1:-1:-1;;;;;196999:29:0;;;;;;;;;;;;;;;;;;;;;;;196727:309;;;:::o;141477:379::-;141541:13;141567:8;141578:7;:14;141567:25;;141605:21;141640:3;141629:15;;;;;;;;;;;;;;;;;;;;;;29:2:-1;21:6;17:15;117:4;105:10;97:6;88:34;136:17;;-1:-1;141629:15:0;-1:-1:-1;141605:39:0;-1:-1:-1;141660:6:0;141655:167;141676:3;141672:1;:7;141655:167;;;141701:13;141724:7;141732:1;141724:10;;;;;;;;;;;;;;141701:34;;141770:39;141790:6;141798:10;141770:19;:39::i;:::-;141765:45;;;;;;;;141752:7;141760:1;141752:10;;;;;;;;;;;;;;;;;:58;-1:-1:-1;141681:3:0;;141655:167;;;-1:-1:-1;141841:7:0;141477:379;-1:-1:-1;;;141477:379:0:o;169229:1554::-;169487:6;;;:49;;;-1:-1:-1;;;169487:49:0;;-1:-1:-1;;;;;169487:49:0;;;;;;;;;;;;169365:4;;;;;;169487:6;;;:25;;:49;;;;;;;;;;;;;;;:6;:49;;;5:2:-1;;;;30:1;27;20:12;5:2;169487:49:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;169487:49:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;169487:49:0;169578:6;;;:51;;;-1:-1:-1;;;169578:51:0;;-1:-1:-1;;;;;169578:51:0;;;;;;;;;;;;169487:49;;-1:-1:-1;169547:28:0;;169578:6;;;;;:25;;:51;;;;;169487:49;;169578:51;;;;;;;;:6;:51;;;5:2:-1;;;;30:1;27;20:12;5:2;169578:51:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;169578:51:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;169578:51:0;;-1:-1:-1;169644:26:0;;;:58;;-1:-1:-1;169674:28:0;;169644:58;169640:126;;;169732:17;169719:35;-1:-1:-1;169752:1:0;;-1:-1:-1;169719:35:0;;-1:-1:-1;;169719:35:0;169640:126;170159:25;170194:16;-1:-1:-1;;;;;170187:43:0;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;170187:45:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;170187:45:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;170187:45:0;;-1:-1:-1;170269:16:0;170296:20;;:::i;:::-;170327:22;;:::i;:::-;170360:16;;:::i;:::-;170401:91;170406:45;;;;;;;;170421:28;;170406:45;;;170453:38;;;;;;;;170468:21;170453:38;;;170401:4;:91::i;:::-;170389:103;;170517:85;170522:40;;;;;;;;170537:23;170522:40;;;170564:37;;;;;;;;170579:20;170564:37;;;170517:4;:85::i;:::-;170503:99;;170621:28;170626:9;170637:11;170621:4;:28::i;:::-;170613:36;;170676:44;170695:5;170702:17;170676:18;:44::i;:::-;170746:14;;-1:-1:-1;170662:58:0;-1:-1:-1;;;;;;;;169229:1554:0;;;;;;;:::o;116121:68::-;;;;;;;;;;;;;;;;;;;;;;;;:::o;158381:969::-;158679:19;;158573:4;;-1:-1:-1;;;158679:19:0;;;;158678:20;158670:48;;;;;-1:-1:-1;;;158670:48:0;;;;;;;;;;;;-1:-1:-1;;;158670:48:0;;;;;;;;;;;;;;;-1:-1:-1;;;;;158795:25:0;;;;;;:7;:25;;;;;:34;;;158794:35;;:72;;-1:-1:-1;;;;;;158834:23:0;;;;;;:7;:23;;;;;:32;;;158833:33;158794:72;158790:141;;;158895:23;158890:29;;158790:141;158996:14;-1:-1:-1;;;;;158989:34:0;;:36;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;158989:36:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;158989:36:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;158989:36:0;158947:38;;;-1:-1:-1;;;158947:38:0;;;;-1:-1:-1;;;;;158947:78:0;;;;:36;;;;;:38;;;;;158989:36;;158947:38;;;;;;;:36;:38;;;5:2:-1;;;;30:1;27;20:12;5:2;158947:38:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;158947:38:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;158947:38:0;-1:-1:-1;;;;;158947:78:0;;158943:150;;159054:26;159049:32;;158943:150;159142:38;159163:16;159142:20;:38::i;:::-;159191:49;159213:16;159231:8;159191:21;:49::i;:::-;159251:51;159273:16;159291:10;159251:21;:51::i;:::-;159327:14;159315:27;158381:969;-1:-1:-1;;;;;;158381:969:0:o;150402:2020::-;-1:-1:-1;;;;;150602:28:0;;150496:4;150602:28;;;:20;:28;;;;;;;;150601:29;150593:58;;;;;-1:-1:-1;;;150593:58:0;;;;;;;;;;;;-1:-1:-1;;;150593:58:0;;;;;;;;;;;;;;;-1:-1:-1;;;;;150669:15:0;;;;;;:7;:15;;;;;:24;;;150664:94;;150722:23;150717:29;;150664:94;-1:-1:-1;;;;;150775:15:0;;;;;;;:7;:15;;;;;;;;:43;;;;;:33;;;;:43;;;;;;150770:574;;150921:10;-1:-1:-1;;;;;150921:20:0;;;150913:54;;;;;-1:-1:-1;;;150913:54:0;;;;;;;;;;;;-1:-1:-1;;;150913:54:0;;;;;;;;;;;;;;;151038:9;151050:49;151077:10;151090:8;151050:19;:49::i;:::-;151038:61;-1:-1:-1;151125:14:0;151118:3;:21;;;;;;;;;151114:78;;151172:3;151167:9;;;;;;;;151160:16;;;;;151114:78;-1:-1:-1;;;;;151288:15:0;;;;;;;:7;:15;;;;;;;;:43;;;;;:33;;;;:43;;;;;;151281:51;;;;150770:574;;151360:6;;;:41;;;-1:-1:-1;;;151360:41:0;;-1:-1:-1;;;;;151360:41:0;;;;;;;;;;;;:6;;;;;:25;;:41;;;;;;;;;;;;;;;:6;:41;;;5:2:-1;;;;30:1;27;20:12;5:2;151360:41:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;151360:41:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;151360:41:0;151356:109;;151435:17;151430:23;;151356:109;-1:-1:-1;;;;;151496:18:0;;151479:14;151496:18;;;:10;:18;;;;;;151592:14;;151588:248;;151623:17;151650:6;-1:-1:-1;;;;;151643:27:0;;:29;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;151643:29:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;151643:29:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;151643:29:0;;-1:-1:-1;151687:21:0;151711:32;151643:29;151730:12;151711:4;:32::i;:::-;151687:56;;151785:9;151766:16;:28;151758:66;;;;;-1:-1:-1;;;151758:66:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;151588:248;;;151849:9;151862:14;151880:82;151920:8;151937:6;151946:1;151949:12;151880:39;:82::i;:::-;151848:114;;-1:-1:-1;151848:114:0;;-1:-1:-1;151984:14:0;;-1:-1:-1;151977:3:0;:21;;;;;;;;;151973:70;;152027:3;152022:9;;;;;;;;152015:16;;;;;;;151973:70;152057:13;;152053:87;;152099:28;152094:34;;152053:87;152189:22;;:::i;:::-;152214:45;;;;;;;;152236:6;-1:-1:-1;;;;;152229:26:0;;:28;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;152229:28:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;152229:28:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;152229:28:0;152214:45;;152189:70;-1:-1:-1;152270:41:0;152291:6;152189:70;152270:20;:41::i;:::-;152322:52;152344:6;152352:8;152362:11;152322:21;:52::i;:::-;152399:14;152387:27;150402:2020;-1:-1:-1;;;;;;;;150402:2020:0:o;113446:49::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;113446:49:0;;-1:-1:-1;113446:49:0;;-1:-1:-1;113446:49:0:o;112647:47::-;;;-1:-1:-1;;;;;112647:47:0;;:::o;197368:509::-;197498:21;:19;:21::i;:::-;197490:62;;;;;-1:-1:-1;;;197490:62:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;197582:14;;197628:19;;197615:32;;:68;;;;;197664:12;:19;197651:9;:32;197615:68;197607:121;;;;-1:-1:-1;;;197607:121:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;197746:6;197741:129;197762:9;197758:1;:13;197741:129;;;197793:65;197813:7;197821:1;197813:10;;;;;;;;;;;;;;197825:12;197838:1;197825:15;;;;;;;;;;;;;;197842:12;197855:1;197842:15;;;;;;;;;;;;;;197793:19;:65::i;:::-;197773:3;;197741:129;;172685:1639;172782:4;172851:5;;-1:-1:-1;;;;;172851:5:0;172837:10;:19;172833:130;;172880:71;172885:18;172905:45;172880:4;:71::i;:::-;172873:78;;;;172833:130;-1:-1:-1;;;;;173035:24:0;;173011:21;173035:24;;;:7;:24;;;;;173075:15;;;;173070:130;;173114:74;173119:23;173144:43;173114:4;:74::i;:::-;173107:81;;;;;173070:130;173212:33;;:::i;:::-;-1:-1:-1;173248:44:0;;;;;;;;;;;;173348:20;;:::i;:::-;-1:-1:-1;173371:44:0;;;;;;;;;140258:6;173371:44;;173430:46;173371:44;173453:22;173430:11;:46::i;:::-;173426:169;;;173500:83;173505:31;173538:44;173500:4;:83::i;:::-;173493:90;;;;;;;173426:169;173669:32;;;;;:74;;-1:-1:-1;173705:6:0;;;:33;;;-1:-1:-1;;;173705:33:0;;-1:-1:-1;;;;;173705:33:0;;;;;;;;;;;;:6;;;;;:25;;:33;;;;;;;;;;;;;;;:6;:33;;;5:2:-1;;;;30:1;27;20:12;5:2;173705:33:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;173705:33:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;173705:33:0;:38;173669:74;173665:186;;;173767:72;173772:17;173791:47;173767:4;:72::i;173665:186::-;173986:31;;;;;174028:61;;;;174191:85;;;-1:-1:-1;;;;;174191:85:0;;;;;;;;;;;;;;;;;;;;;;;;;;;174301:14;174289:27;172685:1639;-1:-1:-1;;;;;;;172685:1639:0:o;115935:68::-;;;;;;;;;;;;;;;;;;;;;;;;:::o;114739:33::-;;;-1:-1:-1;;;114739:33:0;;;;;:::o;112996:31::-;;;;:::o;147948:443::-;148042:4;148059:12;148074:53;148096:6;148104:8;148114:12;148074:21;:53::i;:::-;148059:68;-1:-1:-1;148142:31:0;;148138:78;;148197:7;-1:-1:-1;148190:14:0;;148138:78;148265:28;148286:6;148265:20;:28::i;:::-;148304:39;148326:6;148334:8;148304:21;:39::i;:::-;148368:14;148356:27;147948:443;-1:-1:-1;;;;;147948:443:0:o;116268:42::-;;;;;;;;;;;;;:::o;143553:2177::-;143614:4;143631:13;143654;143631:37;;143759:9;143770:15;143787;143808:6;-1:-1:-1;;;;;143808:25:0;;143834:10;143808:37;;;;;;;;;;;;;-1:-1:-1;;;;;143808:37:0;-1:-1:-1;;;;;143808:37:0;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;143808:37:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;143808:37:0;;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;-1:-1;143808:37:0;;;;;;;;;;;;;-1:-1:-1;143808:37:0;;-1:-1:-1;143808:37:0;-1:-1:-1;143864:9:0;;143856:59;;;;-1:-1:-1;;;143856:59:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;144013:15;;144009:127;;144052:72;144057:28;144087:36;144052:4;:72::i;:::-;144045:79;;;;;;;;144009:127;144229:12;144244:60;144266:13;144281:10;144293;144244:21;:60::i;:::-;144229:75;-1:-1:-1;144319:12:0;;144315:123;;144355:71;144366:15;144383:33;144418:7;144355:10;:71::i;:::-;144348:78;;;;;;;;;144315:123;-1:-1:-1;;;;;144480:24:0;;144450:27;144480:24;;;:7;:24;;;;;;;;144629:10;144598:42;;:30;;;:42;;;;;;;;;144593:103;;144669:14;144657:27;;;;;;;;;;144593:103;144800:10;144769:42;;;;:30;;;:42;;;;;;;;144762:49;;-1:-1:-1;;144762:49:0;;;144971:13;:25;;;;;;144939:57;;;;;;;;;;;;;;;;;:29;;:57;;;144971:25;144939:57;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;144939:57:0;;;;;;;;;;;;;;;;-1:-1:-1;;145018:20:0;;144939:57;;-1:-1:-1;145018:20:0;;-1:-1:-1;145007:8:0;;-1:-1:-1;;145081:162:0;145102:3;145098:1;:7;145081:162;;;145151:6;-1:-1:-1;;;;;145131:26:0;:13;145145:1;145131:16;;;;;;;;;;;;;;-1:-1:-1;;;;;145131:26:0;;145127:105;;;145191:1;145178:14;;145211:5;;145127:105;145107:3;;145081:162;;;;145372:3;145359:10;:16;145352:24;;;;145522:10;145478:27;145508:25;;;:13;:25;;;;;145580:17;;145508:25;;-1:-1:-1;;145580:21:0;;;145569:33;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;145569:33:0;145544:10;145555;145544:22;;;;;;;;;;;;;;;;;:58;;-1:-1:-1;;;;;;145544:58:0;-1:-1:-1;;;;;145544:58:0;;;;;;;;;;145613:19;;;;-1:-1:-1;;145613:19:0;;;:::i;:::-;-1:-1:-1;145650:32:0;;;-1:-1:-1;;;;;145650:32:0;;;;145671:10;145650:32;;;;;;;;;;;;;;;;;145707:14;145695:27;143553:2177;-1:-1:-1;;;;;;;;;;;;143553:2177:0:o;117657:33::-;;;;;;:::o;112340:20::-;;;-1:-1:-1;;;;;112340:20:0;;:::o;117800:45::-;;;;;;;;;;;;;:::o;194621:1090::-;194745:6;194740:808;194761:7;:14;194757:1;:18;194740:808;;;194797:13;194813:7;194821:1;194813:10;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;194846:24:0;;;;;;:7;:24;;;;;;;:33;194813:10;;-1:-1:-1;194846:33:0;;194838:67;;;;;-1:-1:-1;;;194838:67:0;;;;;;;;;;;;-1:-1:-1;;;194838:67:0;;;;;;;;;;;;;;;194937:4;194924:17;;;;194920:355;;;194962:22;;:::i;:::-;194987:37;;;;;;;;195002:6;-1:-1:-1;;;;;195002:18:0;;:20;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;195002:20:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;195002:20:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;195002:20:0;194987:37;;194962:62;-1:-1:-1;195043:50:0;195072:6;194962:62;195043:20;:50::i;:::-;195117:6;195112:148;195133:7;:14;195129:1;:18;195112:148;;;195177:63;195207:6;195216:7;195224:1;195216:10;;;;;;;;;;;;;;195228:11;195177:21;:63::i;:::-;195149:3;;195112:148;;;;194920:355;;195306:4;195293:17;;;;195289:248;;;195331:37;195360:6;195331:20;:37::i;:::-;195392:6;195387:135;195408:7;:14;195404:1;:18;195387:135;;;195452:50;195482:6;195491:7;195499:1;195491:10;;;;;;;;;;;;;;195452:21;:50::i;:::-;195424:3;;195387:135;;;;195289:248;-1:-1:-1;194777:3:0;;194740:808;;;-1:-1:-1;195563:6:0;195558:146;195579:7;:14;195575:1;:18;195558:146;;;195640:52;195657:7;195665:1;195657:10;;;;;;;;;;;;;;195669;:22;195680:7;195688:1;195680:10;;;;;;;;;;;;;;-1:-1:-1;;;;;195669:22:0;-1:-1:-1;;;;;195669:22:0;;;;;;;;;;;;;195640:16;:52::i;:::-;195615:10;:22;195626:7;195634:1;195626:10;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;195615:22:0;;;;;;;;;;;-1:-1:-1;195615:22:0;:77;195595:3;;195558:146;;30747:116;30800:4;30824:31;30829:1;30832;30824:31;;;;;;;;;;;;;-1:-1:-1;;;30824:31:0;;;:4;:31::i;31382:120::-;31435:4;31459:35;31464:1;31467;31459:35;;;;;;;;;;;;;-1:-1:-1;;;31459:35:0;;;:4;:35::i;187812:974::-;-1:-1:-1;;;;;187945:22:0;;187908:34;187945:22;;;:14;:22;;;;;;;;187997:15;:23;;;;;;187945:22;;188052:56;188059:16;:14;:16::i;:::-;188052:56;;;;;;;;;;;;;;;;;:6;:56::i;:::-;188167:17;;188031:77;;-1:-1:-1;188119:16:0;;188138:48;;188143:17;;;;;-1:-1:-1;;;188167:17:0;;;188138:4;:48::i;:::-;188119:67;;188215:1;188201:11;:15;:34;;;;;188234:1;188220:11;:15;188201:34;188197:582;;;188252:17;188272:54;188284:6;-1:-1:-1;;;;;188277:27:0;;:29;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;188277:29:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;188277:29:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;188277:29:0;188308:17;188272:4;:54::i;:::-;188252:74;;188341:15;188359:30;188364:11;188377;188359:4;:30::i;:::-;188341:48;;188404:19;;:::i;:::-;188441:1;188426:12;:16;:77;;188482:21;;;;;;;;188500:1;188482:21;;;188426:77;;;188445:34;188454:10;188466:12;188445:8;:34::i;:::-;188551:37;;;;;;;;;188569:17;;-1:-1:-1;;;;;188569:17:0;188551:37;;188404:99;;-1:-1:-1;188538:98:0;;188546:50;;188404:99;188546:4;:50::i;:::-;:59;188538:98;;;;;;;;;;;;;;;;;:7;:98::i;:::-;188518:118;;-1:-1:-1;;;;;;188518:118:0;-1:-1:-1;;;;;188518:118:0;;;;188651:31;-1:-1:-1;;;188651:31:0;;;;;;;-1:-1:-1;188197:582:0;;-1:-1:-1;;188197:582:0;;188704:15;;188700:79;;188736:31;;;;;-1:-1:-1;;;188736:31:0;-1:-1:-1;;;;;188736:31:0;;;;;;187812:974;;;;;;:::o;191081:1773::-;-1:-1:-1;;;;;191530:22:0;;;191493:34;191530:22;;;:14;:22;;;;;;;;191582:17;;191631:16;:24;;;;;:34;;;;;;;;;;;;;;-1:-1:-1;;;;;191582:17:0;;;191774:48;;;;191530:22;;191839:18;;:52;;;;-1:-1:-1;;;;191861:30:0;;;191839:52;191835:361;;;-1:-1:-1;;;;191835:361:0;192296:24;;:::i;:::-;192323:52;;;;;;;;192341:32;192346:11;192359:13;192341:4;:32::i;:::-;192323:52;;;192296:79;;192388:19;192410:69;192422:6;-1:-1:-1;;;;;192415:34:0;;192450:8;192415:44;;;;;;;;;;;;;-1:-1:-1;;;;;192415:44:0;-1:-1:-1;;;;;192415:44:0;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;192410:69:0;192388:91;;192573:18;192594:32;192599:14;192615:10;192594:4;:32::i;:::-;-1:-1:-1;;;;;192667:20:0;;192639;192667;;;:10;:20;;;;;;192573:53;;-1:-1:-1;192639:20:0;192662:41;;192573:53;192662:4;:41::i;:::-;-1:-1:-1;;;;;192714:20:0;;;;;;;:10;:20;;;;;;;;;:38;;;192770:76;;;;;;;;;;;;;192639:64;;-1:-1:-1;192714:20:0;;192770:76;;;;;;;;;;;;;;191081:1773;;;;;;;;;;:::o;165750:2941::-;165935:5;165942:4;165948;165967:37;;:::i;:::-;-1:-1:-1;;;;;166144:22:0;;166052:9;166144:22;;;:13;:22;;;;;;;;166119:47;;;;;;;;;;;;;;;;;:22;;:47;;166144:22;166119:47;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;166119:47:0;;;;;;;;;;;;;;;;-1:-1:-1;166119:47:0;;-1:-1:-1;166182:6:0;;-1:-1:-1;;;;166177:2163:0;166198:6;:13;166194:1;:17;166177:2163;;;166233:12;166248:6;166255:1;166248:9;;;;;;;;;;;;;;166233:24;;166418:5;-1:-1:-1;;;;;166418:24:0;;166443:7;166418:33;;;;;;;;;;;;;-1:-1:-1;;;;;166418:33:0;-1:-1:-1;;;;;166418:33:0;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;166418:33:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;166418:33:0;;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;-1:-1;166418:33:0;;;;;;;;;;;;;;;;;166389:25;;166342:109;166369:18;;;166342:109;;;;166349:18;;;166342:109;;;;166418:33;-1:-1:-1;166470:9:0;;166466:166;;-1:-1:-1;166589:20:0;;-1:-1:-1;166611:1:0;;-1:-1:-1;166611:1:0;;-1:-1:-1;166581:35:0;;-1:-1:-1;;;;166581:35:0;166466:166;166670:65;;;;;;;;;-1:-1:-1;;;;;166685:23:0;;;-1:-1:-1;166685:23:0;;;:7;:23;;;;;:48;;;166670:65;;166646:21;;;:89;;;;166770:42;;;;;;;-1:-1:-1;;;166785:25:0;166770:42;;166750:17;;;:62;166910:6;;;:32;;-1:-1:-1;;;166910:32:0;;;;;;;;;;;:6;;;:25;;:32;;;;;166670:65;166910:32;;;;;:6;:32;;;5:2:-1;;;;30:1;27;20:12;5:2;166910:32:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;166910:32:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;166910:32:0;166883:24;;;:59;;;166957:102;;-1:-1:-1;167019:17:0;;-1:-1:-1;167038:1:0;;-1:-1:-1;167038:1:0;;-1:-1:-1;167011:32:0;;-1:-1:-1;;;;167011:32:0;166957:102;167092:41;;;;;;;;;167107:24;;;;167092:41;;167073:16;;;:60;167275:21;;;;167298:17;;;;167265:70;;167270:46;;:4;:46::i;:::-;167318:4;:16;;;167265:4;:70::i;:::-;167244:18;;;:91;;;167482:18;;;;167502;;167436:85;;167244:91;167482:18;167436:25;:85::i;:::-;167415:106;;167660:16;;;;167678:18;;;;167698:25;;;;167634:90;;167660:16;167678:18;167634:25;:90::i;:::-;167606:25;;;:118;-1:-1:-1;;;;;167812:21:0;;;;;;;167808:521;;;167989:86;168015:4;:18;;;168035:12;168049:4;:25;;;167989;:86::i;:::-;167961:25;;;:114;;;168255:16;;;;168229:84;;168273:12;;168229:25;:84::i;:::-;168201:25;;;:112;167808:521;-1:-1:-1;166213:3:0;;166177:2163;;;-1:-1:-1;168449:25:0;;;;168428:18;;:46;168424:260;;;-1:-1:-1;;168536:25:0;;;;168515:18;;168499:14;;-1:-1:-1;168515:46:0;;-1:-1:-1;168499:14:0;;-1:-1:-1;168491:74:0;;168424:260;-1:-1:-1;;168653:18:0;;168625:25;;;;;168606:14;;-1:-1:-1;168606:14:0;;-1:-1:-1;168625:46:0;;-1:-1:-1;168598:74:0;;186666:918;-1:-1:-1;;;;;186769:22:0;;186732:34;186769:22;;;:14;:22;;;;;;;;186821:15;:23;;;;;;186769:22;;186876:56;186883:16;:14;:16::i;186876:56::-;186991:17;;186855:77;;-1:-1:-1;186943:16:0;;186962:48;;186967:17;;;;;-1:-1:-1;;;186991:17:0;;;186962:4;:48::i;:::-;186943:67;;187039:1;187025:11;:15;:34;;;;;187058:1;187044:11;:15;187025:34;187021:556;;;187076:17;187103:6;-1:-1:-1;;;;;187096:26:0;;:28;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;187096:28:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;187096:28:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;187096:28:0;;-1:-1:-1;187139:15:0;187157:30;187162:11;187175;187157:4;:30::i;:::-;187139:48;;187202:19;;:::i;:::-;187239:1;187224:12;:16;:77;;187280:21;;;;;;;;187298:1;187280:21;;;187224:77;;;187243:34;187252:10;187264:12;187243:8;:34::i;:::-;187349:37;;;;;;;;;187367:17;;-1:-1:-1;;;;;187367:17:0;187349:37;;187202:99;;-1:-1:-1;187336:98:0;;187344:50;;187202:99;187344:4;:50::i;187336:98::-;187316:118;;-1:-1:-1;;;;;;187316:118:0;-1:-1:-1;;;;;187316:118:0;;;;187449:31;-1:-1:-1;;;187449:31:0;;;;;;;-1:-1:-1;187021:556:0;;-1:-1:-1;;187021:556:0;;187502:15;;187498:79;;187534:31;;;;;-1:-1:-1;;;187534:31:0;-1:-1:-1;;;;;187534:31:0;;;;;;186666:918;;;;;:::o;189040:1686::-;-1:-1:-1;;;;;189459:22:0;;;189422:34;189459:22;;;:14;:22;;;;;;;;189511:17;;189560:16;:24;;;;;:34;;;;;;;;;;;;;;-1:-1:-1;;;;;189511:17:0;;;189702:48;;;;189459:22;;189767:18;;:52;;;;-1:-1:-1;;;;189789:30:0;;;189767:52;189763:361;;;-1:-1:-1;;;;189763:361:0;190217:24;;:::i;:::-;190244:52;;;;;;;;190262:32;190267:11;190280:13;190262:4;:32::i;:::-;190244:52;;;190217:79;;190309:19;190338:6;-1:-1:-1;;;;;190331:24:0;;190356:8;190331:34;;;;;;;;;;;;;-1:-1:-1;;;;;190331:34:0;-1:-1:-1;;;;;190331:34:0;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;190331:34:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;190331:34:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;190331:34:0;;-1:-1:-1;190445:18:0;190466:32;190331:34;190487:10;190466:4;:32::i;:::-;-1:-1:-1;;;;;190539:20:0;;190511;190539;;;:10;:20;;;;;;190445:53;;-1:-1:-1;190511:20:0;190534:41;;190445:53;190534:4;:41::i;:::-;-1:-1:-1;;;;;190586:20:0;;;;;;;:10;:20;;;;;;;;;:38;;;190642:76;;;;;;;;;;;;;190511:64;;-1:-1:-1;190586:20:0;;190642:76;;;;;;;;;;;;;;189040:1686;;;;;;;;;:::o;19210:153::-;19271:4;19293:33;19306:3;19301:9;;;;;;;;19317:4;19312:10;;;;;;;;19293:33;;;;;;;;;;;;;19324:1;19293:33;;;;;;;;;;;;;19351:3;19346:9;;;;;;;163739:187;163816:5;163823:4;163829;163853:65;163893:7;163909:1;163913;163916;163853:39;:65::i;:::-;163846:72;;;;;;163739:187;;;;;:::o;28699:174::-;28777:4;28794:18;;:::i;:::-;28815:15;28820:1;28823:6;28815:4;:15::i;:::-;28794:36;;28848:17;28857:7;28848:8;:17::i;32580:122::-;32633:4;32657:37;32662:1;32665;32657:37;;;;;;;;;;;;;;;;;:4;:37::i;184650:148::-;184704:4;184742:5;;-1:-1:-1;;;;;184742:5:0;184728:10;:19;;:62;;-1:-1:-1;184765:25:0;;-1:-1:-1;;;;;184765:25:0;184751:10;:39;184728:62;184721:69;;184650:148;:::o;176479:250::-;176548:6;176543:137;176564:10;:17;176560:21;;176543:137;;;176636:6;-1:-1:-1;;;;;176612:31:0;:10;176623:1;176612:13;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;176612:13:0;:31;;176604:64;;;;;-1:-1:-1;;;176604:64:0;;;;;;;;;;;;-1:-1:-1;;;176604:64:0;;;;;;;;;;;;;;;176583:4;;176543:137;;;-1:-1:-1;176690:10:0;27::-1;;39:1;23:18;;45:23;;-1:-1;176690:31:0;;;;;;;;-1:-1:-1;;;;;;176690:31:0;-1:-1:-1;;;;;176690:31:0;;;;;;;;;;176479:250::o;176737:825::-;176800:18;176821:56;176828:16;:14;:16::i;176821:56::-;-1:-1:-1;;;;;176927:22:0;;176890:34;176927:22;;;:14;:22;;;;;;;;176997:14;:22;;;;;;177101:17;;176800:77;;-1:-1:-1;176927:22:0;;-1:-1:-1;;;;;177101:17:0;177097:155;;177205:35;;-1:-1:-1;;;;;;177205:35:0;-1:-1:-1;;;177205:35:0;;;177097:155;177268:17;;-1:-1:-1;;;;;177268:17:0;177264:155;;177372:35;;-1:-1:-1;;;;;;177372:35:0;-1:-1:-1;;;177372:35:0;;;177264:155;177523:31;;;;;;-1:-1:-1;;;177523:31:0;-1:-1:-1;;;;;177523:31:0;;;;;;;;177503:51;;;;;;;;;;-1:-1:-1;176737:825:0:o;148399:871::-;-1:-1:-1;;;;;148528:15:0;;148506:4;148528:15;;;:7;:15;;;;;:24;;;148523:94;;148581:23;148576:29;;148523:94;-1:-1:-1;;;;;148728:15:0;;;;;;;:7;:15;;;;;;;;:43;;;;;:33;;;;:43;;;;;;148723:104;;148800:14;148795:20;;148723:104;148932:9;148945:14;148963:82;149003:8;149020:6;149029:12;149043:1;148963:39;:82::i;:::-;148931:114;;-1:-1:-1;148931:114:0;;-1:-1:-1;149067:14:0;;-1:-1:-1;149060:3:0;:21;;;;;;;;;149056:70;;149110:3;149105:9;;;;;;;;149098:16;;;;;;149056:70;149140:13;;149136:87;;149182:28;149177:34;;196059:337;196130:4;196147:7;196161:15;:13;:15::i;:::-;196208:28;;;-1:-1:-1;;;196208:28:0;;196230:4;196208:28;;;;;;196147:30;;-1:-1:-1;196188:17:0;;-1:-1:-1;;;;;196208:13:0;;;;;:28;;;;;;;;;;;;;;:13;:28;;;5:2:-1;;;;30:1;27;20:12;5:2;196208:28:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;196208:28:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;196208:28:0;;-1:-1:-1;196251:10:0;;;;;:36;;;196275:12;196265:6;:22;;196251:36;196247:118;;;196304:3;-1:-1:-1;;;;;196304:12:0;;196317:4;196323:6;196304:26;;;;;;;;;;;;;-1:-1:-1;;;;;196304:26:0;-1:-1:-1;;;;;196304:26:0;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;196304:26:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;196304:26:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;196352:1:0;;-1:-1:-1;196345:8:0;;-1:-1:-1;;;196345:8:0;196247:118;-1:-1:-1;196382:6:0;;196059:337;-1:-1:-1;;;196059:337:0:o;142142:1018::-;-1:-1:-1;;;;;142270:24:0;;142222:5;142270:24;;;:7;:24;;;;;142312:21;;;;142307:135;;142407:23;142400:30;;;;;142307:135;-1:-1:-1;;;;;142458:40:0;;;;;;:30;;;:40;;;;;;;;:48;;:40;:48;142454:133;;;142561:14;142554:21;;;;;142454:133;-1:-1:-1;;;;;142975:40:0;;;;;;;:30;;;:40;;;;;;;;:47;;-1:-1:-1;;142975:47:0;143018:4;142975:47;;;;;;143033:13;:23;;;;;27:10:-1;;23:18;;;45:23;;143033:36:0;;;;;;;;;;;;;;-1:-1:-1;;;;;;143033:36:0;;;;;;;143087:31;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;143138:14:0;;142142:1018;-1:-1:-1;;;142142:1018:0:o;31676:159::-;31741:10;;:::i;:::-;31771:56;;;;;;;;27977:4;31786:28;31791:1;:10;;;31803:1;:10;;;31786:4;:28::i;:::-;:39;;;;;;31771:56;;31764:63;31676:159;-1:-1:-1;;;31676:159:0:o;32968:164::-;33033:10;;:::i;:::-;33063:61;;;;;;;;33078:44;33083:26;33088:1;:10;;;27977:4;33083;:26::i;:::-;33111:10;;33078:4;:44::i;:::-;33063:61;;33056:68;32968:164;-1:-1:-1;;;32968:164:0:o;185095:1343::-;-1:-1:-1;;;;;185219:24:0;;185195:21;185219:24;;;:7;:24;;;;;185262:15;;;;185254:52;;;;;-1:-1:-1;;;185254:52:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;185323:32:0;;;;;;:15;:32;;;;;;:47;;185319:505;;185606:37;185635:6;185606:20;:37::i;:::-;-1:-1:-1;;;;;185704:32:0;;;;;;:15;:32;;;;;;;;;:46;;;185770:42;;;;;;;;;;;;;;;;;185319:505;-1:-1:-1;;;;;185840:32:0;;;;;;:15;:32;;;;;;:47;;185836:595;;186123:22;;:::i;:::-;186148:37;;;;;;;;186163:6;-1:-1:-1;;;;;186163:18:0;;:20;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;186163:20:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;186163:20:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;186163:20:0;186148:37;;186123:62;-1:-1:-1;186200:50:0;186229:6;186123:62;186200:20;:50::i;:::-;-1:-1:-1;;;;;186311:32:0;;;;;;:15;:32;;;;;;;;;:46;;;186377:42;;;;;;;;;;;;;;;;;185836:595;185095:1343;;;;:::o;29310:141::-;29429:14;29413:13;;:30;;29310:141::o;19486:187::-;19571:4;19593:43;19606:3;19601:9;;;;;;;;19617:4;19612:10;;;;;;;;19593:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;19661:3;19656:9;;;;;;;30871:179;30952:4;30978:5;;;31010:12;31002:6;;;;30994:29;;;;-1:-1:-1;;;30994:29:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;90:11;;;84:18;71:11;;;64:39;52:2;45:10;8:100;;;12:14;30994:29:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;31041:1:0;30871:179;-1:-1:-1;;;;30871:179:0:o;31510:158::-;31591:4;31624:12;31616:6;;;;31608:29;;;;-1:-1:-1;;;31608:29:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;27:10:-1;;8:100;;90:11;;;84:18;71:11;;;64:39;52:2;45:10;8:100;;31608:29:0;-1:-1:-1;;;31655:5:0;;;31510:158::o;30254:161::-;30329:6;30367:12;-1:-1:-1;;;30356:9:0;;30348:32;;;;-1:-1:-1;;;30348:32:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;27:10:-1;;8:100;;90:11;;;84:18;71:11;;;64:39;52:2;45:10;8:100;;30348:32:0;-1:-1:-1;30405:1:0;;30254:161;-1:-1:-1;;30254:161:0:o;33281:126::-;33340:4;33364:35;33369:17;33374:1;27977:4;33369;:17::i;:::-;33388:10;;33364:4;:35::i;34178:147::-;34235:13;;:::i;:::-;34268:49;;;;;;;;34286:29;34291:20;34296:1;-1:-1:-1;;;34291:4:0;:20::i;:::-;34313:1;34286:4;:29::i;30579:160::-;30650:13;;:::i;:::-;30683:48;;;;;;;;30701:28;30706:1;:10;;;30718:1;:10;;;30701:4;:28::i;30081:165::-;30157:7;30197:12;-1:-1:-1;;;30185:10:0;;30177:33;;;;-1:-1:-1;;;30177:33:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;27:10:-1;;8:100;;90:11;;;84:18;71:11;;;64:39;52:2;45:10;8:100;;32445:127:0;32507:4;-1:-1:-1;;;32531:19:0;32536:1;32539;:10;;;32531:4;:19::i;:::-;:33;;;;;;;32445:127;-1:-1:-1;;;32445:127:0:o;29018:208::-;29116:4;29133:18;;:::i;:::-;29154:15;29159:1;29162:6;29154:4;:15::i;:::-;29133:36;;29187:31;29192:17;29201:7;29192:8;:17::i;:::-;29211:6;29187:4;:31::i;31843:133::-;31902:10;;:::i;:::-;31932:36;;;;;;;;31947:19;31952:1;:10;;;31964:1;31947:4;:19::i;28373:213::-;28555:12;27977:4;28555:23;;;28373:213::o;32710:250::-;32791:4;32812:6;;;:16;;-1:-1:-1;32822:6:0;;32812:16;32808:57;;;-1:-1:-1;32852:1:0;32845:8;;32808:57;32884:5;;;32888:1;32884;:5;:1;32908:5;;;;;:10;32920:12;32900:33;;;;;-1:-1:-1;;;32900:33:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;27:10:-1;;8:100;;90:11;;;84:18;71:11;;;64:39;52:2;45:10;8:100;;33892:113:0;33945:4;33969:28;33974:1;33977;33969:28;;;;;;;;;;;;;-1:-1:-1;;;33969:28:0;;;34094:4;34126:12;34119:5;34111:28;;;;-1:-1:-1;;;34111:28:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;27:10:-1;;8:100;;90:11;;;84:18;71:11;;;64:39;52:2;45:10;8:100;;34111:28:0;;34161:1;34157;:5;;;;;;;34013:157;-1:-1:-1;;;;34013:157:0:o;136670:63204::-;;;;;;;;;;;;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;:::i;:::-;;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;

Swarm Source

bzzr://11d51fbd4e0a03c138e2cbdbd71d79a896490f2a738a9e23bbff09fdce256dbb
Block Transaction Gas Used Reward
Age Block Fee Address BC Fee Address Voting Power Jailed Incoming
Block Uncle Number Difficulty Gas Used Reward
Loading
Loading