Skip to content

Commit

Permalink
fix: overrides
Browse files Browse the repository at this point in the history
  • Loading branch information
doomsower committed Jan 3, 2024
1 parent 5e5ade6 commit f1fc0f6
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 6 deletions.
6 changes: 4 additions & 2 deletions src/services/liquidate/LiquidatorServiceV2.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,9 @@ export class LiquidatorServiceV2
account.creditFacade,
executor,
);
this.log.debug(`liquidating ${account.addr} in ${account.creditManager}`);
this.log.debug(
`liquidating v2 ${account.addr} in ${account.creditManager}`,
);
const tx = await facade[
"liquidateCreditAccount(address,address,uint256,bool,(address,bytes)[])"
](
Expand All @@ -84,7 +86,7 @@ export class LiquidatorServiceV2
0,
true,
calls,
optimistic ? { gasLimit: 29e6 } : undefined,
optimistic ? { gasLimit: 29e6 } : {},
);
return tx;
}
Expand Down
6 changes: 4 additions & 2 deletions src/services/liquidate/LiquidatorServiceV3.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,12 +81,14 @@ export class LiquidatorServiceV3
account.creditFacade,
executor,
);
this.log.debug(`liquidating ${account.addr} in ${account.creditManager}`);
this.log.debug(
`liquidating v3 ${account.addr} in ${account.creditManager}`,
);
const tx = await facade.liquidateCreditAccount(
account.addr,
this.keyService.address,
calls,
optimistic ? { gasLimit: 29e6 } : undefined,
optimistic ? { gasLimit: 29e6 } : {},
);
return tx;
}
Expand Down
4 changes: 3 additions & 1 deletion src/services/scan/ScanServiceV2.ts
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,9 @@ export class ScanServiceV2 extends AbstractScanService {
);

if (accountsToLiquidate.length) {
this.log.debug(`Accounts to liquidate: ${accountsToLiquidate.length}`);
this.log.debug(
`v2 accounts to liquidate: ${accountsToLiquidate.length}`,
);
if (config.optimisticLiquidations) {
await this.liquidateOptimistically(accountsToLiquidate);
} else {
Expand Down
4 changes: 3 additions & 1 deletion src/services/scan/ScanServiceV3.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,9 @@ export class ScanServiceV3 extends AbstractScanService {
blockTag: atBlock,
});
const accounts = accountsRaw.map(a => new CreditAccountData(a));
this.log.debug(`Accounts to liquidate in ${atBlock}: ${accounts.length}`);
this.log.debug(
`v3 accounts to liquidate in ${atBlock}: ${accounts.length}`,
);
if (config.optimisticLiquidations) {
await this.liquidateOptimistically(accounts);
} else {
Expand Down

0 comments on commit f1fc0f6

Please sign in to comment.