Skip to content

Commit

Permalink
Use Ownable from Open Zeppelin
Browse files Browse the repository at this point in the history
  • Loading branch information
maryokhin committed Nov 28, 2017
1 parent d5648b9 commit 84cedc3
Show file tree
Hide file tree
Showing 14 changed files with 34 additions and 62 deletions.
4 changes: 2 additions & 2 deletions contracts/RocketDepositToken.sol
Expand Up @@ -2,8 +2,8 @@ pragma solidity 0.4.18;

import 'zeppelin-solidity/contracts/math/SafeMath.sol';
import 'zeppelin-solidity/contracts/token/ERC20.sol';
import 'zeppelin-solidity/contracts/ownership/Ownable.sol';

import "./contract/Owned.sol";
import "./interface/RocketStorageInterface.sol";
import "./interface/RocketSettingsInterface.sol";
import "./lib/Arithmetic.sol";
Expand All @@ -12,7 +12,7 @@ import "./lib/Arithmetic.sol";
/// @title The Rocket Pool Deposit Token - Can be used as a backing of your deposit and traded with others while staking
/// @author David Rugendyke

contract RocketDepositToken is ERC20, Owned {
contract RocketDepositToken is ERC20, Ownable {

/**** Properties ***********/

Expand Down
5 changes: 2 additions & 3 deletions contracts/RocketFactory.sol
Expand Up @@ -4,16 +4,15 @@ pragma solidity 0.4.18;
* Note: Since this contract handles contract creation by other contracts, it's deployment gas usage will be high depending on the amount of contracts it can create.
* For the moment it supports the RocketPoolMini creations, but if more automatic contract creations are added, be wary of the gas for deployment as it may exceed the block gas limit
***/
import 'zeppelin-solidity/contracts/ownership/Ownable.sol';

import "./RocketPoolMini.sol";
import "./interface/RocketStorageInterface.sol";
import "./contract/Owned.sol";


/// @title Where we build the rockets! New contracts created by Rocket Pool are done here so they can be tracked.
/// @author David Rugendyke

contract RocketFactory is Owned {
contract RocketFactory is Ownable {

/**** Properties ***********/

Expand Down
6 changes: 3 additions & 3 deletions contracts/RocketNode.sol
@@ -1,16 +1,16 @@
pragma solidity 0.4.18;

import 'zeppelin-solidity/contracts/ownership/Ownable.sol';

import "./RocketPoolMini.sol";
import "./interface/RocketStorageInterface.sol";
import "./interface/RocketSettingsInterface.sol";
import "./interface/RocketPoolInterface.sol";
import "./contract/Owned.sol";


/// @title The Rocket Smart Node contract - more methods for nodes will be moved from RocketPool to here when metropolis is released
/// @author David Rugendyke

contract RocketNode is Owned {
contract RocketNode is Ownable {

/**** Properties ***********/

Expand Down
6 changes: 3 additions & 3 deletions contracts/RocketPartnerAPI.sol
@@ -1,6 +1,7 @@
pragma solidity 0.4.18;

import "./contract/Owned.sol";
import 'zeppelin-solidity/contracts/ownership/Ownable.sol';

import "./interface/RocketUserInterface.sol";
import "./interface/RocketStorageInterface.sol";
import "./interface/RocketSettingsInterface.sol";
Expand All @@ -10,8 +11,7 @@ import "./interface/RocketPoolInterface.sol";
/// @title RocketPartnerAPI - Used by Rocket Pool partners to access the Rocket Pool network
/// @author David Rugendyke

contract RocketPartnerAPI is Owned {

contract RocketPartnerAPI is Ownable {

/**** RocketNode ************/

Expand Down
5 changes: 3 additions & 2 deletions contracts/RocketPool.sol
@@ -1,6 +1,7 @@
pragma solidity 0.4.18;

import "./contract/Owned.sol";
import 'zeppelin-solidity/contracts/ownership/Ownable.sol';

import "./RocketPoolMini.sol";
import "./interface/RocketUserInterface.sol";
import "./interface/RocketFactoryInterface.sol";
Expand All @@ -12,7 +13,7 @@ import "./interface/RocketSettingsInterface.sol";
/// @title First alpha of an Ethereum POS pool - Rocket Pool! - This is the primary upgradable contract
/// @author David Rugendyke

contract RocketPool is Owned {
contract RocketPool is Ownable {



Expand Down
6 changes: 3 additions & 3 deletions contracts/RocketPoolMini.sol
@@ -1,15 +1,15 @@
pragma solidity 0.4.18;

import 'zeppelin-solidity/contracts/ownership/Ownable.sol';

import "./interface/RocketStorageInterface.sol";
import "./interface/RocketSettingsInterface.sol";
import "./interface/CasperInterface.sol";
import "./contract/Owned.sol";


/// @title A minipool under the main RocketPool, all major logic is contained within the RocketPoolMiniDelegate contract which is upgradable when minipools are deployed
/// @author David Rugendyke

contract RocketPoolMini is Owned {
contract RocketPoolMini is Ownable {

/**** Properties ***********/

Expand Down
6 changes: 3 additions & 3 deletions contracts/RocketPoolMiniDelegate.sol
@@ -1,20 +1,20 @@
pragma solidity 0.4.18;

import 'zeppelin-solidity/contracts/math/SafeMath.sol';
import 'zeppelin-solidity/contracts/math/SafeMath.sol';
import 'zeppelin-solidity/contracts/ownership/Ownable.sol';

import "./RocketDepositToken.sol";
import "./interface/RocketStorageInterface.sol";
import "./interface/RocketSettingsInterface.sol";
import "./interface/RocketPoolInterface.sol";
import "./interface/CasperInterface.sol";
import "./contract/Owned.sol";
import "./lib/Arithmetic.sol";


/// @title The minipool delegate, should contain all primary logic for methods that minipools use, is entirely upgradable so that currently deployed pools can get any bug fixes or additions - storage here MUST match the minipool contract
/// @author David Rugendyke

contract RocketPoolMiniDelegate is Owned {
contract RocketPoolMiniDelegate is Ownable {

/**** Properties ***********/

Expand Down
5 changes: 3 additions & 2 deletions contracts/RocketSettings.sol
@@ -1,12 +1,13 @@
pragma solidity 0.4.18;

import "./contract/Owned.sol";
import 'zeppelin-solidity/contracts/ownership/Ownable.sol';

import "./interface/RocketStorageInterface.sol";

/// @title Common settings that are used across all spoke contracts, mostly the main rocketpool and the mini pools it creates
/// @author David Rugendyke

contract RocketSettings is Owned {
contract RocketSettings is Ownable {

/**** Properties ***********/

Expand Down
4 changes: 2 additions & 2 deletions contracts/RocketStorage.sol
@@ -1,12 +1,12 @@
pragma solidity 0.4.18;

import "./contract/Owned.sol";
import 'zeppelin-solidity/contracts/ownership/Ownable.sol';


/// @title The primary persistent storage for Rocket Pool
/// @author David Rugendyke

contract RocketStorage is Owned {
contract RocketStorage is Ownable {


/**** Storage Types *******/
Expand Down
6 changes: 3 additions & 3 deletions contracts/RocketUpgrade.sol
@@ -1,14 +1,14 @@
pragma solidity 0.4.18;

import "./contract/Owned.sol";
import 'zeppelin-solidity/contracts/ownership/Ownable.sol';

import "./RocketStorage.sol";


/// @title Upgrades for Rocket Pool network contracts
/// @author David Rugendyke

contract RocketUpgrade is Owned {

contract RocketUpgrade is Ownable {

/**** Properties ***********/

Expand Down
6 changes: 3 additions & 3 deletions contracts/RocketUser.sol
@@ -1,6 +1,7 @@
pragma solidity 0.4.18;

import "./contract/Owned.sol";
import 'zeppelin-solidity/contracts/ownership/Ownable.sol';

import "./RocketPoolMini.sol";
import "./RocketDepositToken.sol";
import "./interface/RocketStorageInterface.sol";
Expand All @@ -11,8 +12,7 @@ import "./interface/RocketPoolInterface.sol";
/// @title Rocket Pool Users
/// @author David Rugendyke

contract RocketUser is Owned {

contract RocketUser is Ownable {

/**** Properties ************/

Expand Down
28 changes: 0 additions & 28 deletions contracts/contract/Owned.sol

This file was deleted.

5 changes: 2 additions & 3 deletions contracts/contract/casper/DummyCasper.sol
@@ -1,13 +1,12 @@
pragma solidity 0.4.18;

import "../../contract/Owned.sol";

import 'zeppelin-solidity/contracts/ownership/Ownable.sol';

/// @title A dummy shell Casper contract used to simulate sending to and receiving from the actual Casper contract when it's completed.
// Obviously this could change a lot and in no way reflects the actual Casper code, it's just a basic contract simulation based on the Mauve Paper for Rocket Pool to interact with until actual Casper is done or specified 100%.
/// @author David Rugendyke

contract DummyCasper is Owned {
contract DummyCasper is Ownable {

/**** Storage ************/
uint256 public blockTime;
Expand Down
4 changes: 2 additions & 2 deletions contracts/interface/CasperInterface.sol
@@ -1,11 +1,11 @@
pragma solidity 0.4.18;

import "../contract/Owned.sol";
import 'zeppelin-solidity/contracts/ownership/Ownable.sol';

/// @title An interface for Caspers methods that RocketPool will need (this will obviously change a bit until Casper is spec'd 100%, but allows for easier integration)
/// @author David Rugendyke

contract CasperInterface is Owned {
contract CasperInterface is Ownable {
/// @dev A valid registered node validation code
modifier registeredValidator(address validatorSenderAddress) {_;}
/// @dev Deposit at the casper contract
Expand Down

0 comments on commit 84cedc3

Please sign in to comment.