creation_sourcecode: {{
    "language": "Solidity",
    "sources": {
      "@chainlink/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol": {
        "content": "// SPDX-License-Identifier: MIT\npragma solidity ^0.8.0;\n\ninterface AggregatorV3Interface {\n  function decimals() external view returns (uint8);\n\n  function description() external view returns (string memory);\n\n  function version() external view returns (uint256);\n\n  function getRoundData(\n    uint80 _roundId\n  ) external view returns (uint80 roundId, int256 answer, uint256 startedAt, uint256 updatedAt, uint80 answeredInRound);\n\n  function latestRoundData()\n    external\n    view\n    returns (uint80 roundId, int256 answer, uint256 startedAt, uint256 updatedAt, uint80 answeredInRound);\n}\n"
      },
      "contracts/TermCombinationPriceFeed.sol": {
        "content": "// SPDX-License-Identifier: MIT\npragma solidity ^0.8.18;\n\nimport {AggregatorV3Interface} from \"@chainlink/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol\";\n\ncontract TermCombinationPriceFeed is AggregatorV3Interface {\n    AggregatorV3Interface immutable assetToPegAggregator;\n    AggregatorV3Interface immutable pegToBaseAggregator;\n\n    uint8 immutable feedDecimals;\n    int256 immutable denominator;\n\n    constructor(\n        AggregatorV3Interface assetToPegAggregator_,\n        AggregatorV3Interface pegToBaseAggregator_,\n        uint8 decimals_\n    ) {\n        assetToPegAggregator = assetToPegAggregator_;\n        pegToBaseAggregator = pegToBaseAggregator_;\n        feedDecimals = decimals_;\n        denominator = int256(\n            10 **\n                (assetToPegAggregator_.decimals() +\n                    pegToBaseAggregator_.decimals())\n        );\n    }\n\n    function decimals() external view returns (uint8) {\n        return feedDecimals;\n    }\n\n    function description() external pure returns (string memory) {\n        return \"Term Finance price feed\";\n    }\n\n    function version() external pure returns (uint256) {\n        return 0;\n    }\n\n    function getRoundData(\n        uint80 /* _roundId */\n    )\n        external\n        pure\n        returns (\n            uint80 roundId,\n            int256 answer,\n            uint256 startedAt,\n            uint256 updatedAt,\n            uint80 answeredInRound\n        )\n    {\n        return (0, 0, 0, 0, 0);\n    }\n\n    function latestRoundData()\n        external\n        view\n        returns (\n            uint80 roundId,\n            int256 answer,\n            uint256 startedAt,\n            uint256 updatedAt,\n            uint80 answeredInRound\n        )\n    {\n        // slither-disable-next-line unused-return\n        (, int256 assetToPegAggregatorPrice, , , ) = assetToPegAggregator\n            .latestRoundData();\n\n        // slither-disable-next-line unused-return\n        (, int256 pegToBaseAggregatorPrice, , , ) = pegToBaseAggregator\n            .latestRoundData();\n\n        if (assetToPegAggregatorPrice <= 0 || pegToBaseAggregatorPrice <= 0) {\n            return (0, 0, 0, 0, 0);\n        }\n\n        int256 assetToBasePrice = (assetToPegAggregatorPrice *\n            pegToBaseAggregatorPrice *\n            int256(10 ** feedDecimals)) / (denominator);\n\n        return (0, assetToBasePrice, 0, 0, 0);\n    }\n}\n"
      }
    },
    "settings": {
      "outputSelection": {
        "*": {
          "*": [
            "evm.bytecode",
            "evm.deployedBytecode",
            "devdoc",
            "userdoc",
            "metadata",
            "abi"
          ]
        }
      },
      "evmVersion": "paris",
      "optimizer": {
        "enabled": false,
        "runs": 200
      },
      "libraries": {}
    }
  }}