diff --git a/contracts/avalanche/connectors/aave/v3-import/helpers.sol b/contracts/avalanche/connectors/aave/v3-import/helpers.sol index 72586c51..0668ab36 100644 --- a/contracts/avalanche/connectors/aave/v3-import/helpers.sol +++ b/contracts/avalanche/connectors/aave/v3-import/helpers.sol @@ -85,10 +85,19 @@ contract AaveHelpers is Helper { data.variableBorrowAmts = new uint256[]( inputData.borrowTokens.length ); + data.variableBorrowAmtsWithFee = new uint256[]( + inputData.borrowTokens.length + ); data.stableBorrowAmts = new uint256[]( inputData.borrowTokens.length ); + data.stableBorrowAmtsWithFee = new uint256[]( + inputData.borrowTokens.length + ); data.totalBorrowAmts = new uint256[](inputData.borrowTokens.length); + data.totalBorrowAmtsWithFee = new uint256[]( + inputData.borrowTokens.length + ); for (uint256 i = 0; i < inputData.borrowTokens.length; i++) { for (uint256 j = i; j < inputData.borrowTokens.length; j++) { if (j != i) { @@ -122,6 +131,9 @@ contract AaveHelpers is Helper { data.stableBorrowAmts[i], inputData.flashLoanFees[i] ); + data.variableBorrowAmtsWithFee[i] = data.variableBorrowAmts[ + i + ]; } data.totalBorrowAmts[i] = add( diff --git a/contracts/mainnet/connectors/aave/v3-import/helpers.sol b/contracts/mainnet/connectors/aave/v3-import/helpers.sol index 6c400105..591394b5 100644 --- a/contracts/mainnet/connectors/aave/v3-import/helpers.sol +++ b/contracts/mainnet/connectors/aave/v3-import/helpers.sol @@ -86,10 +86,19 @@ contract AaveHelpers is Helper { data.variableBorrowAmts = new uint256[]( inputData.borrowTokens.length ); + data.variableBorrowAmtsWithFee = new uint256[]( + inputData.borrowTokens.length + ); data.stableBorrowAmts = new uint256[]( inputData.borrowTokens.length ); + data.stableBorrowAmtsWithFee = new uint256[]( + inputData.borrowTokens.length + ); data.totalBorrowAmts = new uint256[](inputData.borrowTokens.length); + data.totalBorrowAmtsWithFee = new uint256[]( + inputData.borrowTokens.length + ); for (uint256 i = 0; i < inputData.borrowTokens.length; i++) { for (uint256 j = i; j < inputData.borrowTokens.length; j++) { if (j != i) { diff --git a/contracts/polygon/connectors/aave/v3-import/helpers.sol b/contracts/polygon/connectors/aave/v3-import/helpers.sol index 47437037..44fa5360 100644 --- a/contracts/polygon/connectors/aave/v3-import/helpers.sol +++ b/contracts/polygon/connectors/aave/v3-import/helpers.sol @@ -86,10 +86,19 @@ contract AaveHelpers is Helper { data.variableBorrowAmts = new uint256[]( inputData.borrowTokens.length ); + data.variableBorrowAmtsWithFee = new uint256[]( + inputData.borrowTokens.length + ); data.stableBorrowAmts = new uint256[]( inputData.borrowTokens.length ); + data.stableBorrowAmtsWithFee = new uint256[]( + inputData.borrowTokens.length + ); data.totalBorrowAmts = new uint256[](inputData.borrowTokens.length); + data.totalBorrowAmtsWithFee = new uint256[]( + inputData.borrowTokens.length + ); for (uint256 i = 0; i < inputData.borrowTokens.length; i++) { for (uint256 j = i; j < inputData.borrowTokens.length; j++) { if (j != i) {