add setBaseBorrowMin function
This commit is contained in:
@@ -3789,7 +3789,7 @@
|
|||||||
"label": "assetConfigs",
|
"label": "assetConfigs",
|
||||||
"offset": 0,
|
"offset": 0,
|
||||||
"slot": "5",
|
"slot": "5",
|
||||||
"type": "t_mapping(t_address,t_struct(AssetConfig)6696_storage)",
|
"type": "t_mapping(t_address,t_struct(AssetConfig)5841_storage)",
|
||||||
"contract": "LendingStorage",
|
"contract": "LendingStorage",
|
||||||
"src": "contracts/ytLending/LendingStorage.sol:34"
|
"src": "contracts/ytLending/LendingStorage.sol:34"
|
||||||
},
|
},
|
||||||
@@ -3805,7 +3805,7 @@
|
|||||||
"label": "userBasic",
|
"label": "userBasic",
|
||||||
"offset": 0,
|
"offset": 0,
|
||||||
"slot": "7",
|
"slot": "7",
|
||||||
"type": "t_mapping(t_address,t_struct(UserBasic)7413_storage)",
|
"type": "t_mapping(t_address,t_struct(UserBasic)6364_storage)",
|
||||||
"contract": "LendingStorage",
|
"contract": "LendingStorage",
|
||||||
"src": "contracts/ytLending/LendingStorage.sol:43"
|
"src": "contracts/ytLending/LendingStorage.sol:43"
|
||||||
},
|
},
|
||||||
@@ -3883,7 +3883,7 @@
|
|||||||
"label": "bool",
|
"label": "bool",
|
||||||
"numberOfBytes": "1"
|
"numberOfBytes": "1"
|
||||||
},
|
},
|
||||||
"t_struct(InitializableStorage)119_storage": {
|
"t_struct(InitializableStorage)73_storage": {
|
||||||
"label": "struct Initializable.InitializableStorage",
|
"label": "struct Initializable.InitializableStorage",
|
||||||
"members": [
|
"members": [
|
||||||
{
|
{
|
||||||
@@ -3901,7 +3901,7 @@
|
|||||||
],
|
],
|
||||||
"numberOfBytes": "32"
|
"numberOfBytes": "32"
|
||||||
},
|
},
|
||||||
"t_struct(OwnableStorage)59_storage": {
|
"t_struct(OwnableStorage)13_storage": {
|
||||||
"label": "struct OwnableUpgradeable.OwnableStorage",
|
"label": "struct OwnableUpgradeable.OwnableStorage",
|
||||||
"members": [
|
"members": [
|
||||||
{
|
{
|
||||||
@@ -3913,7 +3913,7 @@
|
|||||||
],
|
],
|
||||||
"numberOfBytes": "32"
|
"numberOfBytes": "32"
|
||||||
},
|
},
|
||||||
"t_struct(PausableStorage)463_storage": {
|
"t_struct(PausableStorage)224_storage": {
|
||||||
"label": "struct PausableUpgradeable.PausableStorage",
|
"label": "struct PausableUpgradeable.PausableStorage",
|
||||||
"members": [
|
"members": [
|
||||||
{
|
{
|
||||||
@@ -3925,7 +3925,7 @@
|
|||||||
],
|
],
|
||||||
"numberOfBytes": "32"
|
"numberOfBytes": "32"
|
||||||
},
|
},
|
||||||
"t_struct(ReentrancyGuardStorage)527_storage": {
|
"t_struct(ReentrancyGuardStorage)288_storage": {
|
||||||
"label": "struct ReentrancyGuardUpgradeable.ReentrancyGuardStorage",
|
"label": "struct ReentrancyGuardUpgradeable.ReentrancyGuardStorage",
|
||||||
"members": [
|
"members": [
|
||||||
{
|
{
|
||||||
@@ -3961,11 +3961,11 @@
|
|||||||
"label": "mapping(address => mapping(address => uint256))",
|
"label": "mapping(address => mapping(address => uint256))",
|
||||||
"numberOfBytes": "32"
|
"numberOfBytes": "32"
|
||||||
},
|
},
|
||||||
"t_mapping(t_address,t_struct(AssetConfig)6696_storage)": {
|
"t_mapping(t_address,t_struct(AssetConfig)5841_storage)": {
|
||||||
"label": "mapping(address => struct LendingConfiguration.AssetConfig)",
|
"label": "mapping(address => struct LendingConfiguration.AssetConfig)",
|
||||||
"numberOfBytes": "32"
|
"numberOfBytes": "32"
|
||||||
},
|
},
|
||||||
"t_mapping(t_address,t_struct(UserBasic)7413_storage)": {
|
"t_mapping(t_address,t_struct(UserBasic)6364_storage)": {
|
||||||
"label": "mapping(address => struct LendingStorage.UserBasic)",
|
"label": "mapping(address => struct LendingStorage.UserBasic)",
|
||||||
"numberOfBytes": "32"
|
"numberOfBytes": "32"
|
||||||
},
|
},
|
||||||
@@ -3973,7 +3973,7 @@
|
|||||||
"label": "mapping(address => uint256)",
|
"label": "mapping(address => uint256)",
|
||||||
"numberOfBytes": "32"
|
"numberOfBytes": "32"
|
||||||
},
|
},
|
||||||
"t_struct(AssetConfig)6696_storage": {
|
"t_struct(AssetConfig)5841_storage": {
|
||||||
"label": "struct LendingConfiguration.AssetConfig",
|
"label": "struct LendingConfiguration.AssetConfig",
|
||||||
"members": [
|
"members": [
|
||||||
{
|
{
|
||||||
@@ -4015,7 +4015,7 @@
|
|||||||
],
|
],
|
||||||
"numberOfBytes": "64"
|
"numberOfBytes": "64"
|
||||||
},
|
},
|
||||||
"t_struct(UserBasic)7413_storage": {
|
"t_struct(UserBasic)6364_storage": {
|
||||||
"label": "struct LendingStorage.UserBasic",
|
"label": "struct LendingStorage.UserBasic",
|
||||||
"members": [
|
"members": [
|
||||||
{
|
{
|
||||||
@@ -4573,6 +4573,423 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"ea7c4b1b12eb95df8ad68f46725ffddee6356e42492be9c1bf47d91feaa8aaea": {
|
||||||
|
"address": "0xBA8f2b5b7281Cd6E49dF229819E824bE0CEA6Ea3",
|
||||||
|
"txHash": "0x544ae5570504ea2c6db57b7ca1ee86d9f7950de7579cf861f209c18d7e4afd66",
|
||||||
|
"layout": {
|
||||||
|
"solcVersion": "0.8.28",
|
||||||
|
"storage": [
|
||||||
|
{
|
||||||
|
"label": "baseToken",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "0",
|
||||||
|
"type": "t_address",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:14"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "lendingPriceSource",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "1",
|
||||||
|
"type": "t_address",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:14"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "supplyKink",
|
||||||
|
"offset": 20,
|
||||||
|
"slot": "1",
|
||||||
|
"type": "t_uint64",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:18"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "supplyPerSecondInterestRateSlopeLow",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "2",
|
||||||
|
"type": "t_uint64",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:19"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "supplyPerSecondInterestRateSlopeHigh",
|
||||||
|
"offset": 8,
|
||||||
|
"slot": "2",
|
||||||
|
"type": "t_uint64",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:20"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "supplyPerSecondInterestRateBase",
|
||||||
|
"offset": 16,
|
||||||
|
"slot": "2",
|
||||||
|
"type": "t_uint64",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:22"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "borrowKink",
|
||||||
|
"offset": 24,
|
||||||
|
"slot": "2",
|
||||||
|
"type": "t_uint64",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:23"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "borrowPerSecondInterestRateSlopeLow",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "3",
|
||||||
|
"type": "t_uint64",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:24"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "borrowPerSecondInterestRateSlopeHigh",
|
||||||
|
"offset": 8,
|
||||||
|
"slot": "3",
|
||||||
|
"type": "t_uint64",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:25"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "borrowPerSecondInterestRateBase",
|
||||||
|
"offset": 16,
|
||||||
|
"slot": "3",
|
||||||
|
"type": "t_uint64",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:28"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "storeFrontPriceFactor",
|
||||||
|
"offset": 24,
|
||||||
|
"slot": "3",
|
||||||
|
"type": "t_uint64",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:30"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "baseBorrowMin",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "4",
|
||||||
|
"type": "t_uint104",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:32"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "targetReserves",
|
||||||
|
"offset": 13,
|
||||||
|
"slot": "4",
|
||||||
|
"type": "t_uint104",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:33"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "assetConfigs",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "5",
|
||||||
|
"type": "t_mapping(t_address,t_struct(AssetConfig)5652_storage)",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:34"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "assetList",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "6",
|
||||||
|
"type": "t_array(t_address)dyn_storage",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:38"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "userBasic",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "7",
|
||||||
|
"type": "t_mapping(t_address,t_struct(UserBasic)6175_storage)",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:43"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "userCollateral",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "8",
|
||||||
|
"type": "t_mapping(t_address,t_mapping(t_address,t_uint256))",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:47"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "totalSupplyBase",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "9",
|
||||||
|
"type": "t_uint104",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:52"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "totalBorrowBase",
|
||||||
|
"offset": 13,
|
||||||
|
"slot": "9",
|
||||||
|
"type": "t_uint104",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:54"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "supplyIndex",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "10",
|
||||||
|
"type": "t_uint256",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:55"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "borrowIndex",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "11",
|
||||||
|
"type": "t_uint256",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:56"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "lastAccrualTime",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "12",
|
||||||
|
"type": "t_uint256",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:56"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "collateralReserves",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "13",
|
||||||
|
"type": "t_mapping(t_address,t_uint256)",
|
||||||
|
"contract": "LendingStorage",
|
||||||
|
"src": "contracts/ytLending/LendingStorage.sol:59"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "__gap",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "14",
|
||||||
|
"type": "t_array(t_uint256)50_storage",
|
||||||
|
"contract": "Lending",
|
||||||
|
"src": "contracts/ytLending/Lending.sol:690"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"types": {
|
||||||
|
"t_address": {
|
||||||
|
"label": "address",
|
||||||
|
"numberOfBytes": "20"
|
||||||
|
},
|
||||||
|
"t_bool": {
|
||||||
|
"label": "bool",
|
||||||
|
"numberOfBytes": "1"
|
||||||
|
},
|
||||||
|
"t_struct(InitializableStorage)73_storage": {
|
||||||
|
"label": "struct Initializable.InitializableStorage",
|
||||||
|
"members": [
|
||||||
|
{
|
||||||
|
"label": "_initialized",
|
||||||
|
"type": "t_uint64",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "0"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "_initializing",
|
||||||
|
"type": "t_bool",
|
||||||
|
"offset": 8,
|
||||||
|
"slot": "0"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"numberOfBytes": "32"
|
||||||
|
},
|
||||||
|
"t_struct(OwnableStorage)13_storage": {
|
||||||
|
"label": "struct OwnableUpgradeable.OwnableStorage",
|
||||||
|
"members": [
|
||||||
|
{
|
||||||
|
"label": "_owner",
|
||||||
|
"type": "t_address",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "0"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"numberOfBytes": "32"
|
||||||
|
},
|
||||||
|
"t_struct(PausableStorage)224_storage": {
|
||||||
|
"label": "struct PausableUpgradeable.PausableStorage",
|
||||||
|
"members": [
|
||||||
|
{
|
||||||
|
"label": "_paused",
|
||||||
|
"type": "t_bool",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "0"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"numberOfBytes": "32"
|
||||||
|
},
|
||||||
|
"t_struct(ReentrancyGuardStorage)288_storage": {
|
||||||
|
"label": "struct ReentrancyGuardUpgradeable.ReentrancyGuardStorage",
|
||||||
|
"members": [
|
||||||
|
{
|
||||||
|
"label": "_status",
|
||||||
|
"type": "t_uint256",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "0"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"numberOfBytes": "32"
|
||||||
|
},
|
||||||
|
"t_uint256": {
|
||||||
|
"label": "uint256",
|
||||||
|
"numberOfBytes": "32"
|
||||||
|
},
|
||||||
|
"t_uint64": {
|
||||||
|
"label": "uint64",
|
||||||
|
"numberOfBytes": "8"
|
||||||
|
},
|
||||||
|
"t_array(t_address)dyn_storage": {
|
||||||
|
"label": "address[]",
|
||||||
|
"numberOfBytes": "32"
|
||||||
|
},
|
||||||
|
"t_array(t_uint256)50_storage": {
|
||||||
|
"label": "uint256[50]",
|
||||||
|
"numberOfBytes": "1600"
|
||||||
|
},
|
||||||
|
"t_int104": {
|
||||||
|
"label": "int104",
|
||||||
|
"numberOfBytes": "13"
|
||||||
|
},
|
||||||
|
"t_mapping(t_address,t_mapping(t_address,t_uint256))": {
|
||||||
|
"label": "mapping(address => mapping(address => uint256))",
|
||||||
|
"numberOfBytes": "32"
|
||||||
|
},
|
||||||
|
"t_mapping(t_address,t_struct(AssetConfig)5652_storage)": {
|
||||||
|
"label": "mapping(address => struct LendingConfiguration.AssetConfig)",
|
||||||
|
"numberOfBytes": "32"
|
||||||
|
},
|
||||||
|
"t_mapping(t_address,t_struct(UserBasic)6175_storage)": {
|
||||||
|
"label": "mapping(address => struct LendingStorage.UserBasic)",
|
||||||
|
"numberOfBytes": "32"
|
||||||
|
},
|
||||||
|
"t_mapping(t_address,t_uint256)": {
|
||||||
|
"label": "mapping(address => uint256)",
|
||||||
|
"numberOfBytes": "32"
|
||||||
|
},
|
||||||
|
"t_struct(AssetConfig)5652_storage": {
|
||||||
|
"label": "struct LendingConfiguration.AssetConfig",
|
||||||
|
"members": [
|
||||||
|
{
|
||||||
|
"label": "asset",
|
||||||
|
"type": "t_address",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "0"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "decimals",
|
||||||
|
"type": "t_uint8",
|
||||||
|
"offset": 20,
|
||||||
|
"slot": "0"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "borrowCollateralFactor",
|
||||||
|
"type": "t_uint64",
|
||||||
|
"offset": 21,
|
||||||
|
"slot": "0"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "liquidateCollateralFactor",
|
||||||
|
"type": "t_uint64",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "1"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "liquidationFactor",
|
||||||
|
"type": "t_uint64",
|
||||||
|
"offset": 8,
|
||||||
|
"slot": "1"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "supplyCap",
|
||||||
|
"type": "t_uint128",
|
||||||
|
"offset": 16,
|
||||||
|
"slot": "1"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"numberOfBytes": "64"
|
||||||
|
},
|
||||||
|
"t_struct(UserBasic)6175_storage": {
|
||||||
|
"label": "struct LendingStorage.UserBasic",
|
||||||
|
"members": [
|
||||||
|
{
|
||||||
|
"label": "principal",
|
||||||
|
"type": "t_int104",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "0"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"numberOfBytes": "32"
|
||||||
|
},
|
||||||
|
"t_uint104": {
|
||||||
|
"label": "uint104",
|
||||||
|
"numberOfBytes": "13"
|
||||||
|
},
|
||||||
|
"t_uint128": {
|
||||||
|
"label": "uint128",
|
||||||
|
"numberOfBytes": "16"
|
||||||
|
},
|
||||||
|
"t_uint8": {
|
||||||
|
"label": "uint8",
|
||||||
|
"numberOfBytes": "1"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"namespaces": {
|
||||||
|
"erc7201:openzeppelin.storage.ReentrancyGuard": [
|
||||||
|
{
|
||||||
|
"contract": "ReentrancyGuardUpgradeable",
|
||||||
|
"label": "_status",
|
||||||
|
"type": "t_uint256",
|
||||||
|
"src": "@openzeppelin/contracts-upgradeable/utils/ReentrancyGuardUpgradeable.sol:43",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "0"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"erc7201:openzeppelin.storage.Pausable": [
|
||||||
|
{
|
||||||
|
"contract": "PausableUpgradeable",
|
||||||
|
"label": "_paused",
|
||||||
|
"type": "t_bool",
|
||||||
|
"src": "@openzeppelin/contracts-upgradeable/utils/PausableUpgradeable.sol:21",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "0"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"erc7201:openzeppelin.storage.Ownable": [
|
||||||
|
{
|
||||||
|
"contract": "OwnableUpgradeable",
|
||||||
|
"label": "_owner",
|
||||||
|
"type": "t_address",
|
||||||
|
"src": "@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol:24",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "0"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"erc7201:openzeppelin.storage.Initializable": [
|
||||||
|
{
|
||||||
|
"contract": "Initializable",
|
||||||
|
"label": "_initialized",
|
||||||
|
"type": "t_uint64",
|
||||||
|
"src": "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol:69",
|
||||||
|
"offset": 0,
|
||||||
|
"slot": "0"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"contract": "Initializable",
|
||||||
|
"label": "_initializing",
|
||||||
|
"type": "t_bool",
|
||||||
|
"src": "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol:73",
|
||||||
|
"offset": 8,
|
||||||
|
"slot": "0"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -122,6 +122,19 @@
|
|||||||
"name": "AbsorbDebt",
|
"name": "AbsorbDebt",
|
||||||
"type": "event"
|
"type": "event"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"anonymous": false,
|
||||||
|
"inputs": [
|
||||||
|
{
|
||||||
|
"indexed": false,
|
||||||
|
"internalType": "uint104",
|
||||||
|
"name": "baseBorrowMin",
|
||||||
|
"type": "uint104"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"name": "BaseBorrowMinUpdated",
|
||||||
|
"type": "event"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"anonymous": false,
|
"anonymous": false,
|
||||||
"inputs": [
|
"inputs": [
|
||||||
@@ -532,6 +545,19 @@
|
|||||||
"stateMutability": "view",
|
"stateMutability": "view",
|
||||||
"type": "function"
|
"type": "function"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"inputs": [
|
||||||
|
{
|
||||||
|
"internalType": "uint104",
|
||||||
|
"name": "newBaseBorrowMin",
|
||||||
|
"type": "uint104"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"name": "setBaseBorrowMin",
|
||||||
|
"outputs": [],
|
||||||
|
"stateMutability": "nonpayable",
|
||||||
|
"type": "function"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"inputs": [
|
"inputs": [
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -233,6 +233,19 @@
|
|||||||
"name": "AbsorbDebt",
|
"name": "AbsorbDebt",
|
||||||
"type": "event"
|
"type": "event"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"anonymous": false,
|
||||||
|
"inputs": [
|
||||||
|
{
|
||||||
|
"indexed": false,
|
||||||
|
"internalType": "uint104",
|
||||||
|
"name": "baseBorrowMin",
|
||||||
|
"type": "uint104"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"name": "BaseBorrowMinUpdated",
|
||||||
|
"type": "event"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"anonymous": false,
|
"anonymous": false,
|
||||||
"inputs": [
|
"inputs": [
|
||||||
@@ -1129,6 +1142,19 @@
|
|||||||
"stateMutability": "nonpayable",
|
"stateMutability": "nonpayable",
|
||||||
"type": "function"
|
"type": "function"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"inputs": [
|
||||||
|
{
|
||||||
|
"internalType": "uint104",
|
||||||
|
"name": "newBaseBorrowMin",
|
||||||
|
"type": "uint104"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"name": "setBaseBorrowMin",
|
||||||
|
"outputs": [],
|
||||||
|
"stateMutability": "nonpayable",
|
||||||
|
"type": "function"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"inputs": [
|
"inputs": [
|
||||||
{
|
{
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@@ -15,6 +15,7 @@ interface ILending {
|
|||||||
event BuyCollateral(address indexed buyer, address indexed asset, uint256 baseAmount, uint256 collateralAmount);
|
event BuyCollateral(address indexed buyer, address indexed asset, uint256 baseAmount, uint256 collateralAmount);
|
||||||
event WithdrawReserves(address indexed to, uint256 amount);
|
event WithdrawReserves(address indexed to, uint256 amount);
|
||||||
event TargetReservesUpdated(uint104 targetReserves);
|
event TargetReservesUpdated(uint104 targetReserves);
|
||||||
|
event BaseBorrowMinUpdated(uint104 baseBorrowMin);
|
||||||
|
|
||||||
error Unauthorized();
|
error Unauthorized();
|
||||||
error InsufficientBalance();
|
error InsufficientBalance();
|
||||||
@@ -47,5 +48,5 @@ interface ILending {
|
|||||||
function getCollateralReserves(address asset) external view returns (uint256);
|
function getCollateralReserves(address asset) external view returns (uint256);
|
||||||
function getUtilization() external view returns (uint256);
|
function getUtilization() external view returns (uint256);
|
||||||
function withdrawReserves(address to, uint256 amount) external;
|
function withdrawReserves(address to, uint256 amount) external;
|
||||||
}
|
function setBaseBorrowMin(uint104 newBaseBorrowMin) external;
|
||||||
|
}
|
||||||
@@ -100,6 +100,11 @@ contract Lending is
|
|||||||
emit TargetReservesUpdated(targetReserves);
|
emit TargetReservesUpdated(targetReserves);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function setBaseBorrowMin(uint104 newBaseBorrowMin) external onlyOwner {
|
||||||
|
baseBorrowMin = newBaseBorrowMin;
|
||||||
|
emit BaseBorrowMinUpdated(baseBorrowMin);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @notice 计算累计利息后的索引(不修改状态)
|
* @notice 计算累计利息后的索引(不修改状态)
|
||||||
* @param timeElapsed 经过的时间
|
* @param timeElapsed 经过的时间
|
||||||
@@ -682,5 +687,4 @@ contract Lending is
|
|||||||
* 50个slot = 50 * 32 bytes = 1600 bytes
|
* 50个slot = 50 * 32 bytes = 1600 bytes
|
||||||
*/
|
*/
|
||||||
uint256[50] private __gap;
|
uint256[50] private __gap;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -6,7 +6,7 @@
|
|||||||
"lendingPriceFeedImpl": "0xF1aAd358d6E20Ba946786Bb3E5d34D42F4740dd2",
|
"lendingPriceFeedImpl": "0xF1aAd358d6E20Ba946786Bb3E5d34D42F4740dd2",
|
||||||
"configuratorProxy": "0x189Fe9dbB2f7dA538D3191159fd661779D7BCBd6",
|
"configuratorProxy": "0x189Fe9dbB2f7dA538D3191159fd661779D7BCBd6",
|
||||||
"configuratorImpl": "0xF553843cb7F35378Fd4020d2DFceb90BfD760552",
|
"configuratorImpl": "0xF553843cb7F35378Fd4020d2DFceb90BfD760552",
|
||||||
"lendingImpl": "0xc20e1Dd1eb781C344489828CE3BFCA318CB51430",
|
"lendingImpl": "0xBA8f2b5b7281Cd6E49dF229819E824bE0CEA6Ea3",
|
||||||
"usdcAddress": "0x939cf46F7A4d05da2a37213E7379a8b04528F590",
|
"usdcAddress": "0x939cf46F7A4d05da2a37213E7379a8b04528F590",
|
||||||
"usdcPriceFeed": "0x90c069C4538adAc136E051052E14c1cD799C41B7",
|
"usdcPriceFeed": "0x90c069C4538adAc136E051052E14c1cD799C41B7",
|
||||||
"deployTimestamp": "2026-01-12T05:59:53.030Z",
|
"deployTimestamp": "2026-01-12T05:59:53.030Z",
|
||||||
@@ -29,6 +29,16 @@
|
|||||||
"address": "0x0EF308D70cf35460E26a3Eb42F3442Ff28cbE07C"
|
"address": "0x0EF308D70cf35460E26a3Eb42F3442Ff28cbE07C"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"configTimestamp": "2026-01-12T06:00:25.232Z"
|
"configTimestamp": "2026-01-12T06:00:25.232Z",
|
||||||
|
"upgradeHistory": [
|
||||||
|
{
|
||||||
|
"timestamp": "2026-03-09T07:51:10.667Z",
|
||||||
|
"contract": "Lending",
|
||||||
|
"oldImplementation": "0xc20e1Dd1eb781C344489828CE3BFCA318CB51430",
|
||||||
|
"newImplementation": "0xBA8f2b5b7281Cd6E49dF229819E824bE0CEA6Ea3",
|
||||||
|
"upgrader": "0xa013422A5918CD099C63c8CC35283EACa99a705d"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"lendingUpgradeTimestamp": "2026-03-09T07:51:10.667Z"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
1
out/build-info/731bfff1b9bd0785.json
Normal file
1
out/build-info/731bfff1b9bd0785.json
Normal file
@@ -0,0 +1 @@
|
|||||||
|
{"id":"731bfff1b9bd0785","source_id_to_path":{"0":"contracts/interfaces/IUSDY.sol","1":"contracts/interfaces/IYTLPToken.sol","2":"contracts/interfaces/IYTPoolManager.sol","3":"contracts/interfaces/IYTVault.sol","4":"contracts/ytLp/core/YTPoolManager.sol","5":"contracts/ytLp/core/YTRewardRouter.sol","6":"lib/forge-std/src/Base.sol","7":"lib/forge-std/src/Script.sol","8":"lib/forge-std/src/StdChains.sol","9":"lib/forge-std/src/StdCheats.sol","10":"lib/forge-std/src/StdConstants.sol","11":"lib/forge-std/src/StdJson.sol","12":"lib/forge-std/src/StdMath.sol","13":"lib/forge-std/src/StdStorage.sol","14":"lib/forge-std/src/StdStyle.sol","15":"lib/forge-std/src/StdUtils.sol","16":"lib/forge-std/src/Vm.sol","17":"lib/forge-std/src/console.sol","18":"lib/forge-std/src/console2.sol","19":"lib/forge-std/src/interfaces/IMulticall3.sol","20":"lib/forge-std/src/safeconsole.sol","21":"node_modules/@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol","22":"node_modules/@openzeppelin/contracts-upgradeable/proxy/utils/UUPSUpgradeable.sol","23":"node_modules/@openzeppelin/contracts-upgradeable/utils/ContextUpgradeable.sol","24":"node_modules/@openzeppelin/contracts-upgradeable/utils/PausableUpgradeable.sol","25":"node_modules/@openzeppelin/contracts-upgradeable/utils/ReentrancyGuardUpgradeable.sol","26":"node_modules/@openzeppelin/contracts/interfaces/IERC1363.sol","27":"node_modules/@openzeppelin/contracts/interfaces/IERC165.sol","28":"node_modules/@openzeppelin/contracts/interfaces/IERC1967.sol","29":"node_modules/@openzeppelin/contracts/interfaces/IERC20.sol","30":"node_modules/@openzeppelin/contracts/interfaces/draft-IERC1822.sol","31":"node_modules/@openzeppelin/contracts/proxy/ERC1967/ERC1967Utils.sol","32":"node_modules/@openzeppelin/contracts/proxy/beacon/IBeacon.sol","33":"node_modules/@openzeppelin/contracts/token/ERC20/IERC20.sol","34":"node_modules/@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol","35":"node_modules/@openzeppelin/contracts/utils/Address.sol","36":"node_modules/@openzeppelin/contracts/utils/Errors.sol","37":"node_modules/@openzeppelin/contracts/utils/StorageSlot.sol","38":"node_modules/@openzeppelin/contracts/utils/introspection/IERC165.sol","39":"scripts/test.s.sol"},"language":"Solidity"}
|
||||||
@@ -1 +0,0 @@
|
|||||||
{"id":"d1a89c054fac217c","source_id_to_path":{"0":"contracts/interfaces/IUSDY.sol","1":"contracts/interfaces/IYTLPToken.sol","2":"contracts/interfaces/IYTPoolManager.sol","3":"contracts/interfaces/IYTVault.sol","4":"contracts/ytLp/core/YTPoolManager.sol","5":"contracts/ytLp/core/YTRewardRouter.sol","6":"contracts/ytLp/tokens/USDY.sol","7":"contracts/ytLp/tokens/YTLPToken.sol","8":"lib/forge-std/src/Base.sol","9":"lib/forge-std/src/StdAssertions.sol","10":"lib/forge-std/src/StdChains.sol","11":"lib/forge-std/src/StdCheats.sol","12":"lib/forge-std/src/StdConstants.sol","13":"lib/forge-std/src/StdError.sol","14":"lib/forge-std/src/StdInvariant.sol","15":"lib/forge-std/src/StdJson.sol","16":"lib/forge-std/src/StdMath.sol","17":"lib/forge-std/src/StdStorage.sol","18":"lib/forge-std/src/StdStyle.sol","19":"lib/forge-std/src/StdToml.sol","20":"lib/forge-std/src/StdUtils.sol","21":"lib/forge-std/src/Test.sol","22":"lib/forge-std/src/Vm.sol","23":"lib/forge-std/src/console.sol","24":"lib/forge-std/src/console2.sol","25":"lib/forge-std/src/interfaces/IMulticall3.sol","26":"lib/forge-std/src/safeconsole.sol","27":"node_modules/@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol","28":"node_modules/@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol","29":"node_modules/@openzeppelin/contracts-upgradeable/proxy/utils/UUPSUpgradeable.sol","30":"node_modules/@openzeppelin/contracts-upgradeable/token/ERC20/ERC20Upgradeable.sol","31":"node_modules/@openzeppelin/contracts-upgradeable/utils/ContextUpgradeable.sol","32":"node_modules/@openzeppelin/contracts-upgradeable/utils/PausableUpgradeable.sol","33":"node_modules/@openzeppelin/contracts-upgradeable/utils/ReentrancyGuardUpgradeable.sol","34":"node_modules/@openzeppelin/contracts/interfaces/IERC1363.sol","35":"node_modules/@openzeppelin/contracts/interfaces/IERC165.sol","36":"node_modules/@openzeppelin/contracts/interfaces/IERC1967.sol","37":"node_modules/@openzeppelin/contracts/interfaces/IERC20.sol","38":"node_modules/@openzeppelin/contracts/interfaces/draft-IERC1822.sol","39":"node_modules/@openzeppelin/contracts/interfaces/draft-IERC6093.sol","40":"node_modules/@openzeppelin/contracts/proxy/ERC1967/ERC1967Proxy.sol","41":"node_modules/@openzeppelin/contracts/proxy/ERC1967/ERC1967Utils.sol","42":"node_modules/@openzeppelin/contracts/proxy/Proxy.sol","43":"node_modules/@openzeppelin/contracts/proxy/beacon/IBeacon.sol","44":"node_modules/@openzeppelin/contracts/token/ERC20/ERC20.sol","45":"node_modules/@openzeppelin/contracts/token/ERC20/IERC20.sol","46":"node_modules/@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol","47":"node_modules/@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol","48":"node_modules/@openzeppelin/contracts/utils/Address.sol","49":"node_modules/@openzeppelin/contracts/utils/Context.sol","50":"node_modules/@openzeppelin/contracts/utils/Errors.sol","51":"node_modules/@openzeppelin/contracts/utils/StorageSlot.sol","52":"node_modules/@openzeppelin/contracts/utils/introspection/IERC165.sol","53":"test/CooldownBypassFix.t.sol"},"language":"Solidity"}
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
{"id":"eabedd7944f1777c","source_id_to_path":{"0":"lib/forge-std/src/Base.sol","1":"lib/forge-std/src/Script.sol","2":"lib/forge-std/src/StdChains.sol","3":"lib/forge-std/src/StdCheats.sol","4":"lib/forge-std/src/StdConstants.sol","5":"lib/forge-std/src/StdJson.sol","6":"lib/forge-std/src/StdMath.sol","7":"lib/forge-std/src/StdStorage.sol","8":"lib/forge-std/src/StdStyle.sol","9":"lib/forge-std/src/StdUtils.sol","10":"lib/forge-std/src/Vm.sol","11":"lib/forge-std/src/console.sol","12":"lib/forge-std/src/console2.sol","13":"lib/forge-std/src/interfaces/IMulticall3.sol","14":"lib/forge-std/src/safeconsole.sol","15":"scripts/test.s.sol"},"language":"Solidity"}
|
|
||||||
File diff suppressed because one or more lines are too long
@@ -12,9 +12,9 @@ contract TestFun is Script {
|
|||||||
function run() external {
|
function run() external {
|
||||||
|
|
||||||
address from = 0xa013422A5918CD099C63c8CC35283EACa99a705d;
|
address from = 0xa013422A5918CD099C63c8CC35283EACa99a705d;
|
||||||
address to = 0x20B94C5E5b7361552E0548161a58696aA6FeDBd4;
|
address to = 0x5af5A51F7702024E7387bba7497DC9965C00F16E;
|
||||||
|
|
||||||
bytes memory data = hex"7229bc3c0000000000000000000000000000000000000000000000000de0b6b3a7640000";
|
bytes memory data = hex"8fed0b2c000000000000000000000000939cf46f7a4d05da2a37213e7379a8b04528f59000000000000000000000000000000000000000000000000053444835ec5800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000a013422a5918cd099c63c8cc35283eaca99a705d";
|
||||||
|
|
||||||
vm.startPrank(from);
|
vm.startPrank(from);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user