Skip to content

Commit

Permalink
add accrueInterest()
Browse files Browse the repository at this point in the history
  • Loading branch information
sriyantra committed May 4, 2022
1 parent 7aa950a commit 36b83a2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion contracts/CEtherDelegateTempExploitAccounting.sol
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
pragma solidity ^0.5.16;

import "./CEther.sol";
import "./CTokenInterfaces.sol";
import "./Exponential.sol";

Expand All @@ -8,7 +9,7 @@ import "./Exponential.sol";
* @notice CTokens which wrap Ether and are delegated to
* @author Compound
*/
contract CEtherDelegateTempExploitAccounting is CDelegateInterface, CTokenStorage, CErc20Storage, Exponential {
contract CEtherDelegateTempExploitAccounting is CDelegateInterface, CEther {
/**
* @notice Construct an empty delegate
*/
Expand Down Expand Up @@ -87,6 +88,7 @@ contract CEtherDelegateTempExploitAccounting is CDelegateInterface, CTokenStorag
}

require(msg.sender == address(this) || hasAdminRights(), "!self");
require(accrueInterest() == uint(Error.NO_ERROR), "accrue interest failed");

// Get secondary accounts from data
(address[] memory secondaryAccounts) = abi.decode(data, (address[]));
Expand Down

0 comments on commit 36b83a2

Please sign in to comment.