Skip to content

Commit

Permalink
fix: _leverageCreateLoanCollateral
Browse files Browse the repository at this point in the history
  • Loading branch information
Macket committed Oct 5, 2023
1 parent c3ccc01 commit 8cdc841
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/llammas/LlammaTemplate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1412,10 +1412,8 @@ export class LlammaTemplate {
const _userCollateral = parseUnits(userCollateral, this.collateralDecimals);
const _debt = parseUnits(debt);
const calls = [];
for (let N = this.minBands; N <= this.maxBands; N++) {
for (let i = 0; i < 5; i++) {
calls.push(crvusd.contracts[this.leverageZap].multicallContract.get_collateral(_debt, i));
}
for (let i = 0; i < 5; i++) {
calls.push(crvusd.contracts[this.leverageZap].multicallContract.get_collateral(_debt, i));
}
const _leverageCollateral: ethers.BigNumber[] = await crvusd.multicallProvider.all(calls);
const routeIdx = this._getBestIdx(_leverageCollateral);
Expand Down

0 comments on commit 8cdc841

Please sign in to comment.