Skip to content

Commit

Permalink
Merge pull request #312 from VenusProtocol/VEN-2047
Browse files Browse the repository at this point in the history
[VEN-2047]: Certik audit fix for forced liquidation
  • Loading branch information
Debugger022 authored Oct 13, 2023
2 parents cbd9b18 + ebc9a9b commit 0973a15
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions contracts/Comptroller.sol
Original file line number Diff line number Diff line change
Expand Up @@ -477,7 +477,7 @@ contract Comptroller is

uint256 borrowBalance = VToken(vTokenBorrowed).borrowBalanceStored(borrower);

/* Allow accounts to be liquidated if the market is deprecated or it is a forced liquidation */
/* Allow accounts to be liquidated if it is a forced liquidation */
if (skipLiquidityCheck || isForcedLiquidationEnabled[vTokenBorrowed]) {
if (repayAmount > borrowBalance) {
revert TooMuchRepay();
Expand Down Expand Up @@ -1021,7 +1021,7 @@ contract Comptroller is
revert MarketNotListed(vTokenBorrowed);
}

isForcedLiquidationEnabled[address(vTokenBorrowed)] = enable;
isForcedLiquidationEnabled[vTokenBorrowed] = enable;
emit IsForcedLiquidationEnabledUpdated(vTokenBorrowed, enable);
}

Expand Down

0 comments on commit 0973a15

Please sign in to comment.