Remove redundant inheritance and imports
This commit is contained in:
parent
4784131dca
commit
98698f702f
@ -21,28 +21,13 @@ pragma experimental ABIEncoderV2;
|
||||
|
||||
import "./interfaces/IStaking.sol";
|
||||
import "./sys/MixinParams.sol";
|
||||
import "./sys/MixinFinalizer.sol";
|
||||
import "./stake/MixinStake.sol";
|
||||
import "./staking_pools/MixinStakingPool.sol";
|
||||
import "./fees/MixinExchangeFees.sol";
|
||||
|
||||
|
||||
contract Staking is
|
||||
IStaking,
|
||||
IStakingEvents,
|
||||
MixinAbstract,
|
||||
MixinConstants,
|
||||
Ownable,
|
||||
MixinStorage,
|
||||
MixinExchangeManager,
|
||||
MixinScheduler,
|
||||
MixinParams,
|
||||
MixinStakeStorage,
|
||||
MixinStakeBalances,
|
||||
MixinCumulativeRewards,
|
||||
MixinStakingPoolRewards,
|
||||
MixinFinalizer,
|
||||
MixinStakingPool,
|
||||
MixinStake,
|
||||
MixinExchangeFees
|
||||
{
|
||||
|
@ -27,8 +27,6 @@ import "./interfaces/IStakingProxy.sol";
|
||||
|
||||
contract StakingProxy is
|
||||
IStakingProxy,
|
||||
MixinConstants,
|
||||
Ownable,
|
||||
MixinStorage
|
||||
{
|
||||
using LibProxy for address;
|
||||
|
@ -19,33 +19,20 @@
|
||||
pragma solidity ^0.5.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
import "@0x/contracts-erc20/contracts/src/interfaces/IEtherToken.sol";
|
||||
import "@0x/contracts-exchange-libs/contracts/src/LibMath.sol";
|
||||
import "@0x/contracts-utils/contracts/src/LibRichErrors.sol";
|
||||
import "@0x/contracts-utils/contracts/src/LibSafeMath.sol";
|
||||
import "../libs/LibStakingRichErrors.sol";
|
||||
import "../libs/LibCobbDouglas.sol";
|
||||
import "../interfaces/IStructs.sol";
|
||||
import "../stake/MixinStakeBalances.sol";
|
||||
import "../sys/MixinFinalizer.sol";
|
||||
import "../staking_pools/MixinStakingPool.sol";
|
||||
import "./MixinExchangeManager.sol";
|
||||
|
||||
|
||||
contract MixinExchangeFees is
|
||||
IStakingEvents,
|
||||
MixinAbstract,
|
||||
MixinConstants,
|
||||
Ownable,
|
||||
MixinStorage,
|
||||
MixinExchangeManager,
|
||||
MixinScheduler,
|
||||
MixinStakeStorage,
|
||||
MixinStakeBalances,
|
||||
MixinCumulativeRewards,
|
||||
MixinStakingPoolRewards,
|
||||
MixinFinalizer,
|
||||
MixinStakingPool
|
||||
MixinStakingPool,
|
||||
MixinFinalizer
|
||||
{
|
||||
using LibSafeMath for uint256;
|
||||
|
||||
|
@ -30,8 +30,6 @@ import "../immutable/MixinStorage.sol";
|
||||
/// then it should be removed.
|
||||
contract MixinExchangeManager is
|
||||
IStakingEvents,
|
||||
MixinConstants,
|
||||
Ownable,
|
||||
MixinStorage
|
||||
{
|
||||
/// @dev Asserts that the call is coming from a valid exchange.
|
||||
|
@ -20,23 +20,12 @@ pragma solidity ^0.5.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
import "@0x/contracts-utils/contracts/src/LibSafeMath.sol";
|
||||
import "../staking_pools/MixinStakingPoolRewards.sol";
|
||||
import "../staking_pools/MixinStakingPool.sol";
|
||||
import "../libs/LibStakingRichErrors.sol";
|
||||
|
||||
|
||||
/// @dev This mixin contains logic for managing ZRX tokens and Stake.
|
||||
contract MixinStake is
|
||||
IStakingEvents,
|
||||
MixinAbstract,
|
||||
MixinConstants,
|
||||
Ownable,
|
||||
MixinStorage,
|
||||
MixinScheduler,
|
||||
MixinStakeStorage,
|
||||
MixinStakeBalances,
|
||||
MixinCumulativeRewards,
|
||||
MixinStakingPoolRewards,
|
||||
MixinStakingPool
|
||||
{
|
||||
using LibSafeMath for uint256;
|
||||
|
@ -27,11 +27,6 @@ import "./MixinStakeStorage.sol";
|
||||
/// @dev This mixin contains logic for querying stake balances.
|
||||
/// **** Read MixinStake before continuing ****
|
||||
contract MixinStakeBalances is
|
||||
IStakingEvents,
|
||||
MixinConstants,
|
||||
Ownable,
|
||||
MixinStorage,
|
||||
MixinScheduler,
|
||||
MixinStakeStorage
|
||||
{
|
||||
using LibSafeMath for uint256;
|
||||
|
@ -26,10 +26,6 @@ import "../sys/MixinScheduler.sol";
|
||||
|
||||
/// @dev This mixin contains logic for managing stake storage.
|
||||
contract MixinStakeStorage is
|
||||
IStakingEvents,
|
||||
MixinConstants,
|
||||
Ownable,
|
||||
MixinStorage,
|
||||
MixinScheduler
|
||||
{
|
||||
using LibSafeMath for uint256;
|
||||
|
@ -25,12 +25,6 @@ import "../stake/MixinStakeBalances.sol";
|
||||
|
||||
|
||||
contract MixinCumulativeRewards is
|
||||
IStakingEvents,
|
||||
MixinConstants,
|
||||
Ownable,
|
||||
MixinStorage,
|
||||
MixinScheduler,
|
||||
MixinStakeStorage,
|
||||
MixinStakeBalances
|
||||
{
|
||||
using LibSafeMath for uint256;
|
||||
|
@ -23,19 +23,12 @@ import "@0x/contracts-utils/contracts/src/LibRichErrors.sol";
|
||||
import "@0x/contracts-utils/contracts/src/LibSafeMath.sol";
|
||||
import "../libs/LibStakingRichErrors.sol";
|
||||
import "../interfaces/IStructs.sol";
|
||||
import "../sys/MixinAbstract.sol";
|
||||
import "./MixinStakingPoolRewards.sol";
|
||||
|
||||
|
||||
contract MixinStakingPool is
|
||||
IStakingEvents,
|
||||
MixinAbstract,
|
||||
MixinConstants,
|
||||
Ownable,
|
||||
MixinStorage,
|
||||
MixinScheduler,
|
||||
MixinStakeStorage,
|
||||
MixinStakeBalances,
|
||||
MixinCumulativeRewards,
|
||||
MixinStakingPoolRewards
|
||||
{
|
||||
using LibSafeMath for uint256;
|
||||
|
@ -27,14 +27,7 @@ import "../sys/MixinAbstract.sol";
|
||||
|
||||
|
||||
contract MixinStakingPoolRewards is
|
||||
IStakingEvents,
|
||||
MixinAbstract,
|
||||
MixinConstants,
|
||||
Ownable,
|
||||
MixinStorage,
|
||||
MixinScheduler,
|
||||
MixinStakeStorage,
|
||||
MixinStakeBalances,
|
||||
MixinCumulativeRewards
|
||||
{
|
||||
using LibSafeMath for uint256;
|
||||
|
@ -19,8 +19,6 @@
|
||||
pragma solidity ^0.5.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
import "../interfaces/IStructs.sol";
|
||||
|
||||
|
||||
/// @dev Exposes some internal functions from various contracts to avoid
|
||||
/// cyclical dependencies.
|
||||
|
@ -19,18 +19,12 @@
|
||||
pragma solidity ^0.5.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
import "@0x/contracts-erc20/contracts/src/interfaces/IEtherToken.sol";
|
||||
import "@0x/contracts-utils/contracts/src/LibRichErrors.sol";
|
||||
import "@0x/contracts-utils/contracts/src/LibSafeMath.sol";
|
||||
import "../libs/LibCobbDouglas.sol";
|
||||
import "../libs/LibStakingRichErrors.sol";
|
||||
import "../immutable/MixinStorage.sol";
|
||||
import "../immutable/MixinConstants.sol";
|
||||
import "../interfaces/IStakingEvents.sol";
|
||||
import "../interfaces/IStructs.sol";
|
||||
import "../stake/MixinStakeBalances.sol";
|
||||
import "../staking_pools/MixinStakingPool.sol";
|
||||
import "./MixinScheduler.sol";
|
||||
import "../staking_pools/MixinStakingPoolRewards.sol";
|
||||
|
||||
|
||||
/// @dev This mixin contains functions related to finalizing epochs.
|
||||
@ -39,15 +33,6 @@ import "./MixinScheduler.sol";
|
||||
/// the contract from stalling while we finalize rewards for the previous
|
||||
/// epoch.
|
||||
contract MixinFinalizer is
|
||||
IStakingEvents,
|
||||
MixinAbstract,
|
||||
MixinConstants,
|
||||
Ownable,
|
||||
MixinStorage,
|
||||
MixinScheduler,
|
||||
MixinStakeStorage,
|
||||
MixinStakeBalances,
|
||||
MixinCumulativeRewards,
|
||||
MixinStakingPoolRewards
|
||||
{
|
||||
using LibSafeMath for uint256;
|
||||
|
@ -26,8 +26,6 @@ import "../libs/LibStakingRichErrors.sol";
|
||||
|
||||
contract MixinParams is
|
||||
IStakingEvents,
|
||||
MixinConstants,
|
||||
Ownable,
|
||||
MixinStorage
|
||||
{
|
||||
/// @dev Set all configurable parameters at once.
|
||||
|
@ -33,8 +33,6 @@ import "../interfaces/IStakingEvents.sol";
|
||||
/// and consistent scheduling metric than time. TimeLocks, for example, are measured in epochs.
|
||||
contract MixinScheduler is
|
||||
IStakingEvents,
|
||||
MixinConstants,
|
||||
Ownable,
|
||||
MixinStorage
|
||||
{
|
||||
using LibSafeMath for uint256;
|
||||
|
@ -34,7 +34,6 @@ import "./MixinVaultCore.sol";
|
||||
/// failure mode, it cannot be returned to normal mode; this prevents
|
||||
/// corruption of related state in the staking contract.
|
||||
contract ZrxVault is
|
||||
IVaultCore,
|
||||
IZrxVault,
|
||||
MixinVaultCore
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user