diff --git a/src/views/Lending/Cooler/hooks/useConsolidateCooler.tsx b/src/views/Lending/Cooler/hooks/useConsolidateCooler.tsx index f6841bb28..a7b1c7136 100644 --- a/src/views/Lending/Cooler/hooks/useConsolidateCooler.tsx +++ b/src/views/Lending/Cooler/hooks/useConsolidateCooler.tsx @@ -37,7 +37,7 @@ export const useConsolidateCooler = () => { toCoolerAddress, loanIds, { - gasLimit: loanIds.length <= 30 ? loanIds.length * 1000000 : 30000000, + gasLimit: loanIds.length <= 15 ? loanIds.length * 2000000 : 30000000, }, ); const receipt = await cooler.wait(); diff --git a/src/views/Lending/Cooler/positions/ConsolidateLoan.tsx b/src/views/Lending/Cooler/positions/ConsolidateLoan.tsx index f4cc664df..154ea17ac 100644 --- a/src/views/Lending/Cooler/positions/ConsolidateLoan.tsx +++ b/src/views/Lending/Cooler/positions/ConsolidateLoan.tsx @@ -84,8 +84,8 @@ export const ConsolidateLoans = ({ : selectedVersion === "v2" ? clearingHouseAddresses.v2 : clearingHouseAddresses.v3; - const duration = 90; // Standard duration for consolidated loans - const debtAddress = selectedClearingHouse.debtAddress; + const duration = 121; // Standard duration for consolidated loans + const debtAddress = clearingHouseAddresses.v3.debtAddress; // Show button only if there are loans that can be consolidated const showConsolidateButton = hasV1Loans || hasV2Loans || hasMultipleV3Loans; @@ -184,8 +184,8 @@ export const ConsolidateLoans = ({ <> All existing open loans for this Cooler and Clearinghouse will be repaid and consolidated into a new - loan with a {duration} day duration. You must hold enough {selectedClearingHouse.debtAssetName} in your - wallet to cover the interest owed at consolidation. + loan with a {duration} day duration. You must hold enough {clearingHouseAddresses.v3.debtAssetName} in + your wallet to cover the interest owed at consolidation. Interest Owed At Consolidation - {formatNumber(parseFloat(formatEther(totals.interest)), 4)} {selectedClearingHouse.debtAssetName} + {formatNumber(parseFloat(formatEther(totals.interest)), 4)}{" "} + {clearingHouseAddresses.v3.debtAssetName} @@ -275,14 +276,14 @@ export const ConsolidateLoans = ({ ) : ( Approve {selectedClearingHouse.debtAssetName} for Spending on the Consolidation Contract + <>Approve {clearingHouseAddresses.v3.debtAssetName} for Spending on the Consolidation Contract } spendAmount={allowances?.totalDebtWithFee} - approvalText={`Approve ${selectedClearingHouse.debtAssetName} for Spending`} + approvalText={`Approve ${clearingHouseAddresses.v3.debtAssetName} for Spending`} > {insufficientCollateral - ? `Insufficient ${selectedClearingHouse.debtAssetName} Balance` + ? `Insufficient ${clearingHouseAddresses.v3.debtAssetName} Balance` : "Select loans to consolidate"} )}