Added event when ownership of contract changes
This commit is contained in:
@@ -72,18 +72,18 @@ contract MixinFees is
|
||||
}
|
||||
|
||||
/// @dev Pays the rebates for to market making pool that was active this epoch,
|
||||
/// then updates the epoch and other time-based periods via the scheduler (see MixinScheduler).
|
||||
/// This is intentionally permissionless, and may be called by anyone.
|
||||
/// then updates the epoch and other time-based periods via the scheduler (see MixinScheduler).
|
||||
/// This is intentionally permissionless, and may be called by anyone.
|
||||
function finalizeFees()
|
||||
external
|
||||
{
|
||||
// payout rewards
|
||||
// distribute fees to market maker pools as a reward
|
||||
(uint256 totalActivePools,
|
||||
uint256 totalFeesCollected,
|
||||
uint256 totalWeightedStake,
|
||||
uint256 totalRewardsPaid,
|
||||
uint256 initialContractBalance,
|
||||
uint256 finalContractBalance) = _payMakerRewards();
|
||||
uint256 finalContractBalance) = _distributeFeesAmongMakerPools();
|
||||
emit RewardsPaid(
|
||||
totalActivePools,
|
||||
totalFeesCollected,
|
||||
@@ -131,7 +131,7 @@ contract MixinFees is
|
||||
/// @return totalRewardsPaid Total rewards paid out across all active pools.
|
||||
/// @return initialContractBalance Balance of this contract before paying rewards.
|
||||
/// @return finalContractBalance Balance of this contract after paying rewards.
|
||||
function _payMakerRewards()
|
||||
function _distributeFeesAmongMakerPools()
|
||||
private
|
||||
returns (
|
||||
uint256 totalActivePools,
|
||||
|
||||
@@ -22,13 +22,10 @@ pragma experimental ABIEncoderV2;
|
||||
import "../libs/LibSafeMath.sol";
|
||||
import "../libs/LibSignatureValidator.sol";
|
||||
import "../libs/LibEIP712Hash.sol";
|
||||
|
||||
import "../interfaces/IStructs.sol";
|
||||
import "../interfaces/IStakingEvents.sol";
|
||||
|
||||
import "../immutable/MixinConstants.sol";
|
||||
import "../immutable/MixinStorage.sol";
|
||||
|
||||
import "./MixinRewardVault.sol";
|
||||
|
||||
|
||||
@@ -41,6 +38,10 @@ contract MixinPools is
|
||||
|
||||
using LibSafeMath for uint256;
|
||||
|
||||
/// @dev This mixin contains logic for pools.
|
||||
/// A "pool" can be delegated to by any number of stakers.
|
||||
/// A market maker can create a pool
|
||||
|
||||
modifier onlyPoolOperator(bytes32 poolId) {
|
||||
require(
|
||||
msg.sender == getPoolOperator(poolId),
|
||||
|
||||
@@ -37,6 +37,8 @@ contract MixinRewards is
|
||||
|
||||
using LibSafeMath for uint256;
|
||||
|
||||
/// @dev This mixin contains logic for rewards
|
||||
|
||||
function withdrawOperatorReward(bytes32 poolId, uint256 amount)
|
||||
external
|
||||
onlyPoolOperator(poolId)
|
||||
|
||||
@@ -62,4 +62,10 @@ interface IStakingEvents {
|
||||
uint256 initialContractBalance,
|
||||
uint256 finalContractBalance
|
||||
);
|
||||
|
||||
/// @dev Emitted by MixinOwnable when the contract's ownership changes
|
||||
/// @param newOwner New owner of the contract
|
||||
event OwnershipTransferred(
|
||||
address newOwner
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user