fix typos

This commit is contained in:
Michael Zhu 2019-08-23 13:58:18 -07:00
parent 52ef745f7c
commit cd1fc6a1f0
14 changed files with 56 additions and 52 deletions

View File

@ -41,7 +41,7 @@ If a vulnerability is discovered in the staking contract, operations may be halt
In this worst-case scenario, state has been irreperably corrupted and the staking contracts must be re-deployed. Users withdraw their funds from the vaults and re-stake under the new system, at will. In this worst-case scenario, state has been irreperably corrupted and the staking contracts must be re-deployed. Users withdraw their funds from the vaults and re-stake under the new system, at will.
4. Vaults enter "Catostrophic Failure Mode" allowing users to withdraw their ZRX and Rewards. 4. Vaults enter "Catastrophic Failure Mode" allowing users to withdraw their ZRX and Rewards.
5. A Balance Oracle is deployed for determining the Reward balance of each user. (\*) 5. A Balance Oracle is deployed for determining the Reward balance of each user. (\*)
![](images/architecture_failure_mode.png) ![](images/architecture_failure_mode.png)

View File

@ -22,7 +22,7 @@ pragma solidity ^0.5.9;
/// @dev This vault manages staking pool rewards. /// @dev This vault manages staking pool rewards.
/// Rewards can be deposited and withdraw by the staking contract. /// Rewards can be deposited and withdraw by the staking contract.
/// There is a "Catastrophic Failure Mode" that, when invoked, only /// There is a "Catastrophic Failure Mode" that, when invoked, only
/// allows withdrawals to be made. Once this vault is in catostrophic /// allows withdrawals to be made. Once this vault is in catastrophic
/// failure mode, it cannot be returned to normal mode; this prevents /// failure mode, it cannot be returned to normal mode; this prevents
/// corruption of related state in the staking contract. /// corruption of related state in the staking contract.
interface IStakingPoolRewardVault { interface IStakingPoolRewardVault {

View File

@ -27,7 +27,7 @@ pragma solidity ^0.5.9;
/// Vaults should only be set to Catastrophic Failure Mode iff there is /// Vaults should only be set to Catastrophic Failure Mode iff there is
/// non-recoverable corruption of the staking contracts. If there is a /// non-recoverable corruption of the staking contracts. If there is a
/// recoverable flaw/bug/vulnerability, simply detach the staking contract /// recoverable flaw/bug/vulnerability, simply detach the staking contract
/// by setting its address to `address(0)`. Once in Catostrophic Failure Mode, /// by setting its address to `address(0)`. Once in Catastrophic Failure Mode,
/// a vault cannot be reset to normal mode; this prevents corruption of related /// a vault cannot be reset to normal mode; this prevents corruption of related
/// state in the staking contract. /// state in the staking contract.
interface IVaultCore { interface IVaultCore {
@ -38,9 +38,9 @@ interface IVaultCore {
address stakingContractAddress address stakingContractAddress
); );
/// @dev Emitted when the Staking contract is put into Catostrophic Failure Mode /// @dev Emitted when the Staking contract is put into Catastrophic Failure Mode
/// @param sender Address of sender (`msg.sender`) /// @param sender Address of sender (`msg.sender`)
event InCatostrophicFailureMode( event InCatastrophicFailureMode(
address sender address sender
); );
@ -50,9 +50,9 @@ interface IVaultCore {
function setStakingContract(address payable _stakingContractAddress) function setStakingContract(address payable _stakingContractAddress)
external; external;
/// @dev Vault enters into Catostrophic Failure Mode. /// @dev Vault enters into Catastrophic Failure Mode.
/// *** WARNING - ONCE IN CATOSTROPHIC FAILURE MODE, YOU CAN NEVER GO BACK! *** /// *** WARNING - ONCE IN CATOSTROPHIC FAILURE MODE, YOU CAN NEVER GO BACK! ***
/// Note that only the contract owner can call this function. /// Note that only the contract owner can call this function.
function enterCatostrophicFailure() function enterCatastrophicFailure()
external; external;
} }

View File

@ -23,7 +23,7 @@ pragma solidity ^0.5.9;
/// When a user mints stake, their Zrx Tokens are deposited into this vault. /// When a user mints stake, their Zrx Tokens are deposited into this vault.
/// Similarly, when they burn stake, their Zrx Tokens are withdrawn from this vault. /// Similarly, when they burn stake, their Zrx Tokens are withdrawn from this vault.
/// There is a "Catastrophic Failure Mode" that, when invoked, only /// There is a "Catastrophic Failure Mode" that, when invoked, only
/// allows withdrawals to be made. Once this vault is in catostrophic /// allows withdrawals to be made. Once this vault is in catastrophic
/// failure mode, it cannot be returned to normal mode; this prevents /// failure mode, it cannot be returned to normal mode; this prevents
/// corruption of related state in the staking contract. /// corruption of related state in the staking contract.
interface IZrxVault { interface IZrxVault {
@ -62,21 +62,21 @@ interface IZrxVault {
/// @dev Sets the ERC20 proxy. /// @dev Sets the ERC20 proxy.
/// Note that only the contract owner can call this. /// Note that only the contract owner can call this.
/// Note that this can only be called when *not* in Catostrophic Failure mode. /// Note that this can only be called when *not* in Catastrophic Failure mode.
/// @param erc20ProxyAddress Address of the 0x ERC20 Proxy. /// @param erc20ProxyAddress Address of the 0x ERC20 Proxy.
function setErc20Proxy(address erc20ProxyAddress) function setErc20Proxy(address erc20ProxyAddress)
external; external;
/// @dev Sets the Zrx Asset Data. /// @dev Sets the Zrx Asset Data.
/// Note that only the contract owner can call this. /// Note that only the contract owner can call this.
/// Note that this can only be called when *not* in Catostrophic Failure mode. /// Note that this can only be called when *not* in Catastrophic Failure mode.
/// @param _zrxAssetData Zrx asset data for the ERC20 Proxy. /// @param _zrxAssetData Zrx asset data for the ERC20 Proxy.
function setZrxAssetData(bytes calldata _zrxAssetData) function setZrxAssetData(bytes calldata _zrxAssetData)
external; external;
/// @dev Deposit an `amount` of Zrx Tokens from `owner` into the vault. /// @dev Deposit an `amount` of Zrx Tokens from `owner` into the vault.
/// Note that only the Staking contract can call this. /// Note that only the Staking contract can call this.
/// Note that this can only be called when *not* in Catostrophic Failure mode. /// Note that this can only be called when *not* in Catastrophic Failure mode.
/// @param owner of Zrx Tokens. /// @param owner of Zrx Tokens.
/// @param amount of Zrx Tokens to deposit. /// @param amount of Zrx Tokens to deposit.
function depositFrom(address owner, uint256 amount) function depositFrom(address owner, uint256 amount)
@ -84,14 +84,14 @@ interface IZrxVault {
/// @dev Withdraw an `amount` of Zrx Tokens to `owner` from the vault. /// @dev Withdraw an `amount` of Zrx Tokens to `owner` from the vault.
/// Note that only the Staking contract can call this. /// Note that only the Staking contract can call this.
/// Note that this can only be called when *not* in Catostrophic Failure mode. /// Note that this can only be called when *not* in Catastrophic Failure mode.
/// @param owner of Zrx Tokens. /// @param owner of Zrx Tokens.
/// @param amount of Zrx Tokens to withdraw. /// @param amount of Zrx Tokens to withdraw.
function withdrawFrom(address owner, uint256 amount) function withdrawFrom(address owner, uint256 amount)
external; external;
/// @dev Withdraw ALL Zrx Tokens to `owner` from the vault. /// @dev Withdraw ALL Zrx Tokens to `owner` from the vault.
/// Note that this can only be called when *in* Catostrophic Failure mode. /// Note that this can only be called when *in* Catastrophic Failure mode.
/// @param owner of Zrx Tokens. /// @param owner of Zrx Tokens.
function withdrawAllFrom(address owner) function withdrawAllFrom(address owner)
external external

View File

@ -42,7 +42,7 @@ library LibSignatureValidator {
returns (bool isValid) returns (bool isValid)
{ {
if (signature.length == 0) { if (signature.length == 0) {
LibRichErrors.rrevert(LibStakingRichErrors.LengthGreaterThan0RequiredError()); LibRichErrors.rrevert(LibStakingRichErrors.SignatureLengthGreaterThan0RequiredError());
} }
// Pop last byte off of signature byte array. // Pop last byte off of signature byte array.
@ -78,7 +78,7 @@ library LibSignatureValidator {
// offered explicitly. It can be implicitly created by providing // offered explicitly. It can be implicitly created by providing
// a correctly formatted but incorrect signature. // a correctly formatted but incorrect signature.
} else if (signatureType == IStructs.SignatureType.Invalid) { } else if (signatureType == IStructs.SignatureType.Invalid) {
if (signature.legnth > 0) { if (signature.length > 0) {
LibRichErrors.rrevert(LibStakingRichErrors.SignatureLength0RequiredError( LibRichErrors.rrevert(LibStakingRichErrors.SignatureLength0RequiredError(
signature signature
)); ));
@ -88,7 +88,7 @@ library LibSignatureValidator {
// Signature using EIP712 // Signature using EIP712
} else if (signatureType == IStructs.SignatureType.EIP712) { } else if (signatureType == IStructs.SignatureType.EIP712) {
if (signature.legnth != 65) { if (signature.length != 65) {
LibRichErrors.rrevert(LibStakingRichErrors.SignatureLength65RequiredError( LibRichErrors.rrevert(LibStakingRichErrors.SignatureLength65RequiredError(
signature signature
)); ));
@ -107,7 +107,7 @@ library LibSignatureValidator {
// Signed using web3.eth_sign // Signed using web3.eth_sign
} else if (signatureType == IStructs.SignatureType.EthSign) { } else if (signatureType == IStructs.SignatureType.EthSign) {
if (signature.legnth != 65) { if (signature.length != 65) {
LibRichErrors.rrevert(LibStakingRichErrors.SignatureLength65RequiredError( LibRichErrors.rrevert(LibStakingRichErrors.SignatureLength65RequiredError(
signature signature
)); ));

View File

@ -123,7 +123,7 @@ contract MixinStake is
LibRichErrors.rrevert(LibStakingRichErrors.InsufficientBalanceError( LibRichErrors.rrevert(LibStakingRichErrors.InsufficientBalanceError(
amount, amount,
getDeactivatedStake(owner) getDeactivatedStake(owner)
); ));
} }
_burnStake(owner, amount); _burnStake(owner, amount);
@ -140,7 +140,7 @@ contract MixinStake is
LibRichErrors.rrevert(LibStakingRichErrors.InsufficientBalanceError( LibRichErrors.rrevert(LibStakingRichErrors.InsufficientBalanceError(
amount, amount,
getActivatableStake(owner) getActivatableStake(owner)
); ));
} }
activatedStakeByOwner[owner] = activatedStakeByOwner[owner]._add(amount); activatedStakeByOwner[owner] = activatedStakeByOwner[owner]._add(amount);
@ -158,7 +158,7 @@ contract MixinStake is
LibRichErrors.rrevert(LibStakingRichErrors.InsufficientBalanceError( LibRichErrors.rrevert(LibStakingRichErrors.InsufficientBalanceError(
amount, amount,
getActivatedStake(owner) getActivatedStake(owner)
); ));
} }
activatedStakeByOwner[owner] = activatedStakeByOwner[owner]._sub(amount); activatedStakeByOwner[owner] = activatedStakeByOwner[owner]._sub(amount);

View File

@ -32,7 +32,7 @@ import "../interfaces/IVaultCore.sol";
/// Vaults should only be set to Catastrophic Failure Mode iff there is /// Vaults should only be set to Catastrophic Failure Mode iff there is
/// non-recoverable corruption of the staking contracts. If there is a /// non-recoverable corruption of the staking contracts. If there is a
/// recoverable flaw/bug/vulnerability, simply detach the staking contract /// recoverable flaw/bug/vulnerability, simply detach the staking contract
/// by setting its address to `address(0)`. Once in Catostrophic Failure Mode, /// by setting its address to `address(0)`. Once in Catastrophic Failure Mode,
/// a vault cannot be reset to normal mode; this prevents corruption of related /// a vault cannot be reset to normal mode; this prevents corruption of related
/// state in the staking contract. /// state in the staking contract.
contract MixinVaultCore is contract MixinVaultCore is
@ -43,13 +43,13 @@ contract MixinVaultCore is
// Address of staking contract // Address of staking contract
address payable internal stakingContractAddress; address payable internal stakingContractAddress;
// True iff vault has been set to Catostrophic Failure Mode // True iff vault has been set to Catastrophic Failure Mode
bool internal isInCatostrophicFailure; bool internal isInCatastrophicFailure;
/// @dev Constructor. /// @dev Constructor.
constructor() public { constructor() public {
stakingContractAddress = 0x0000000000000000000000000000000000000000; stakingContractAddress = 0x0000000000000000000000000000000000000000;
isInCatostrophicFailure = false; isInCatastrophicFailure = false;
} }
/// @dev Asserts that the sender (`msg.sender`) is the staking contract. /// @dev Asserts that the sender (`msg.sender`) is the staking contract.
@ -62,9 +62,9 @@ contract MixinVaultCore is
_; _;
} }
/// @dev Asserts that this contract *is in* Catostrophic Failure Mode. /// @dev Asserts that this contract *is in* Catastrophic Failure Mode.
modifier onlyInCatostrophicFailure { modifier onlyInCatastrophicFailure {
if (!isInCatostrophicFailure) { if (!isInCatastrophicFailure) {
LibRichErrors.rrevert( LibRichErrors.rrevert(
LibStakingRichErrors.OnlyCallableInCatastrophicFailureError() LibStakingRichErrors.OnlyCallableInCatastrophicFailureError()
); );
@ -72,9 +72,9 @@ contract MixinVaultCore is
_; _;
} }
/// @dev Asserts that this contract *is not in* Catostrophic Failure Mode. /// @dev Asserts that this contract *is not in* Catastrophic Failure Mode.
modifier onlyNotInCatostrophicFailure { modifier onlyNotInCatastrophicFailure {
if (isInCatostrophicFailure) { if (isInCatastrophicFailure) {
LibRichErrors.rrevert( LibRichErrors.rrevert(
LibStakingRichErrors.OnlyCallableNotInCatastrophicFailureError() LibStakingRichErrors.OnlyCallableNotInCatastrophicFailureError()
); );
@ -93,14 +93,14 @@ contract MixinVaultCore is
emit StakingContractChanged(stakingContractAddress); emit StakingContractChanged(stakingContractAddress);
} }
/// @dev Vault enters into Catostrophic Failure Mode. /// @dev Vault enters into Catastrophic Failure Mode.
/// *** WARNING - ONCE IN CATOSTROPHIC FAILURE MODE, YOU CAN NEVER GO BACK! *** /// *** WARNING - ONCE IN CATOSTROPHIC FAILURE MODE, YOU CAN NEVER GO BACK! ***
/// Note that only the contract owner can call this function. /// Note that only the contract owner can call this function.
function enterCatostrophicFailure() function enterCatastrophicFailure()
external external
onlyOwner onlyOwner
{ {
isInCatostrophicFailure = true; isInCatastrophicFailure = true;
emit InCatostrophicFailureMode(msg.sender); emit InCatastrophicFailureMode(msg.sender);
} }
} }

View File

@ -30,7 +30,7 @@ import "../immutable/MixinConstants.sol";
/// @dev This vault manages staking pool rewards. /// @dev This vault manages staking pool rewards.
/// Rewards can be deposited and withdraw by the staking contract. /// Rewards can be deposited and withdraw by the staking contract.
/// There is a "Catastrophic Failure Mode" that, when invoked, only /// There is a "Catastrophic Failure Mode" that, when invoked, only
/// allows withdrawals to be made. Once this vault is in catostrophic /// allows withdrawals to be made. Once this vault is in catastrophic
/// failure mode, it cannot be returned to normal mode; this prevents /// failure mode, it cannot be returned to normal mode; this prevents
/// corruption of related state in the staking contract. /// corruption of related state in the staking contract.
/// ///
@ -55,7 +55,7 @@ contract StakingPoolRewardVault is
external external
payable payable
onlyStakingContract onlyStakingContract
onlyNotInCatostrophicFailure onlyNotInCatastrophicFailure
{ {
emit RewardDeposited(UNKNOWN_STAKING_POOL_ID, msg.value); emit RewardDeposited(UNKNOWN_STAKING_POOL_ID, msg.value);
} }
@ -68,7 +68,7 @@ contract StakingPoolRewardVault is
external external
payable payable
onlyStakingContract onlyStakingContract
onlyNotInCatostrophicFailure onlyNotInCatastrophicFailure
{ {
// update balance of pool // update balance of pool
uint256 amount = msg.value; uint256 amount = msg.value;
@ -89,7 +89,7 @@ contract StakingPoolRewardVault is
function recordDepositFor(bytes32 poolId, uint256 amount) function recordDepositFor(bytes32 poolId, uint256 amount)
external external
onlyStakingContract onlyStakingContract
onlyNotInCatostrophicFailure onlyNotInCatastrophicFailure
{ {
// update balance of pool // update balance of pool
Balance memory balance = balanceByPoolId[poolId]; Balance memory balance = balanceByPoolId[poolId];
@ -155,7 +155,7 @@ contract StakingPoolRewardVault is
function registerStakingPool(bytes32 poolId, uint8 poolOperatorShare) function registerStakingPool(bytes32 poolId, uint8 poolOperatorShare)
external external
onlyStakingContract onlyStakingContract
onlyNotInCatostrophicFailure onlyNotInCatastrophicFailure
{ {
// operator share must be a valid percentage // operator share must be a valid percentage
if (poolOperatorShare > 100) { if (poolOperatorShare > 100) {

View File

@ -29,7 +29,7 @@ import "./MixinVaultCore.sol";
/// When a user mints stake, their Zrx Tokens are deposited into this vault. /// When a user mints stake, their Zrx Tokens are deposited into this vault.
/// Similarly, when they burn stake, their Zrx Tokens are withdrawn from this vault. /// Similarly, when they burn stake, their Zrx Tokens are withdrawn from this vault.
/// There is a "Catastrophic Failure Mode" that, when invoked, only /// There is a "Catastrophic Failure Mode" that, when invoked, only
/// allows withdrawals to be made. Once this vault is in catostrophic /// allows withdrawals to be made. Once this vault is in catastrophic
/// failure mode, it cannot be returned to normal mode; this prevents /// failure mode, it cannot be returned to normal mode; this prevents
/// corruption of related state in the staking contract. /// corruption of related state in the staking contract.
contract ZrxVault is contract ZrxVault is
@ -70,12 +70,12 @@ contract ZrxVault is
/// @dev Sets the ERC20 proxy. /// @dev Sets the ERC20 proxy.
/// Note that only the contract owner can call this. /// Note that only the contract owner can call this.
/// Note that this can only be called when *not* in Catostrophic Failure mode. /// Note that this can only be called when *not* in Catastrophic Failure mode.
/// @param erc20ProxyAddress Address of the 0x ERC20 Proxy. /// @param erc20ProxyAddress Address of the 0x ERC20 Proxy.
function setErc20Proxy(address erc20ProxyAddress) function setErc20Proxy(address erc20ProxyAddress)
external external
onlyOwner onlyOwner
onlyNotInCatostrophicFailure onlyNotInCatastrophicFailure
{ {
erc20Proxy = IAssetProxy(erc20ProxyAddress); erc20Proxy = IAssetProxy(erc20ProxyAddress);
emit Erc20ProxyChanged(erc20ProxyAddress); emit Erc20ProxyChanged(erc20ProxyAddress);
@ -83,12 +83,12 @@ contract ZrxVault is
/// @dev Sets the Zrx Asset Data. /// @dev Sets the Zrx Asset Data.
/// Note that only the contract owner can call this. /// Note that only the contract owner can call this.
/// Note that this can only be called when *not* in Catostrophic Failure mode. /// Note that this can only be called when *not* in Catastrophic Failure mode.
/// @param _zrxAssetData Zrx asset data for the ERC20 Proxy. /// @param _zrxAssetData Zrx asset data for the ERC20 Proxy.
function setZrxAssetData(bytes calldata _zrxAssetData) function setZrxAssetData(bytes calldata _zrxAssetData)
external external
onlyOwner onlyOwner
onlyNotInCatostrophicFailure onlyNotInCatastrophicFailure
{ {
zrxAssetData = _zrxAssetData; zrxAssetData = _zrxAssetData;
emit ZrxAssetDataChanged(_zrxAssetData); emit ZrxAssetDataChanged(_zrxAssetData);
@ -96,13 +96,13 @@ contract ZrxVault is
/// @dev Deposit an `amount` of Zrx Tokens from `owner` into the vault. /// @dev Deposit an `amount` of Zrx Tokens from `owner` into the vault.
/// Note that only the Staking contract can call this. /// Note that only the Staking contract can call this.
/// Note that this can only be called when *not* in Catostrophic Failure mode. /// Note that this can only be called when *not* in Catastrophic Failure mode.
/// @param owner of Zrx Tokens. /// @param owner of Zrx Tokens.
/// @param amount of Zrx Tokens to deposit. /// @param amount of Zrx Tokens to deposit.
function depositFrom(address owner, uint256 amount) function depositFrom(address owner, uint256 amount)
external external
onlyStakingContract onlyStakingContract
onlyNotInCatostrophicFailure onlyNotInCatastrophicFailure
{ {
// update balance // update balance
balances[owner] = balances[owner]._add(amount); balances[owner] = balances[owner]._add(amount);
@ -121,23 +121,23 @@ contract ZrxVault is
/// @dev Withdraw an `amount` of Zrx Tokens to `owner` from the vault. /// @dev Withdraw an `amount` of Zrx Tokens to `owner` from the vault.
/// Note that only the Staking contract can call this. /// Note that only the Staking contract can call this.
/// Note that this can only be called when *not* in Catostrophic Failure mode. /// Note that this can only be called when *not* in Catastrophic Failure mode.
/// @param owner of Zrx Tokens. /// @param owner of Zrx Tokens.
/// @param amount of Zrx Tokens to withdraw. /// @param amount of Zrx Tokens to withdraw.
function withdrawFrom(address owner, uint256 amount) function withdrawFrom(address owner, uint256 amount)
external external
onlyStakingContract onlyStakingContract
onlyNotInCatostrophicFailure onlyNotInCatastrophicFailure
{ {
_withdrawFrom(owner, amount); _withdrawFrom(owner, amount);
} }
/// @dev Withdraw ALL Zrx Tokens to `owner` from the vault. /// @dev Withdraw ALL Zrx Tokens to `owner` from the vault.
/// Note that this can only be called when *in* Catostrophic Failure mode. /// Note that this can only be called when *in* Catastrophic Failure mode.
/// @param owner of Zrx Tokens. /// @param owner of Zrx Tokens.
function withdrawAllFrom(address owner) function withdrawAllFrom(address owner)
external external
onlyInCatostrophicFailure onlyInCatastrophicFailure
returns (uint256) returns (uint256)
{ {
// get total balance // get total balance

View File

@ -36,7 +36,7 @@
"compile:truffle": "truffle compile" "compile:truffle": "truffle compile"
}, },
"config": { "config": {
"abis": "./generated-artifacts/@(IStaking|IStakingEvents|IStakingPoolRewardVault|IStakingProxy|IStructs|IVaultCore|IWallet|IZrxVault|LibEIP712Hash|LibFeeMath|LibFeeMathTest|LibRewardMath|LibSafeMath|LibSafeMath64|LibSafeMath96|LibSignatureValidator|MixinConstants|MixinDelegatedStake|MixinDeploymentConstants|MixinExchangeFees|MixinExchangeManager|MixinOwnable|MixinScheduler|MixinStake|MixinStakeBalances|MixinStakingPool|MixinStakingPoolRewardVault|MixinStakingPoolRewards|MixinStorage|MixinTimeLockedStake|MixinVaultCore|MixinZrxVault|Staking|StakingPoolRewardVault|StakingProxy|ZrxVault).json", "abis": "./generated-artifacts/@(IStaking|IStakingEvents|IStakingPoolRewardVault|IStakingProxy|IStructs|IVaultCore|IWallet|IZrxVault|LibEIP712Hash|LibFeeMath|LibFeeMathTest|LibRewardMath|LibSafeMath|LibSafeMath64|LibSafeMath96|LibSignatureValidator|LibStakingRichErrors|MixinConstants|MixinDelegatedStake|MixinDeploymentConstants|MixinExchangeFees|MixinExchangeManager|MixinOwnable|MixinScheduler|MixinStake|MixinStakeBalances|MixinStakingPool|MixinStakingPoolRewardVault|MixinStakingPoolRewards|MixinStorage|MixinTimeLockedStake|MixinVaultCore|MixinZrxVault|Staking|StakingPoolRewardVault|StakingProxy|ZrxVault).json",
"abis:comment": "This list is auto-generated by contracts-gen. Don't edit manually." "abis:comment": "This list is auto-generated by contracts-gen. Don't edit manually."
}, },
"repository": { "repository": {

View File

@ -21,6 +21,7 @@ import * as LibSafeMath from '../generated-artifacts/LibSafeMath.json';
import * as LibSafeMath64 from '../generated-artifacts/LibSafeMath64.json'; import * as LibSafeMath64 from '../generated-artifacts/LibSafeMath64.json';
import * as LibSafeMath96 from '../generated-artifacts/LibSafeMath96.json'; import * as LibSafeMath96 from '../generated-artifacts/LibSafeMath96.json';
import * as LibSignatureValidator from '../generated-artifacts/LibSignatureValidator.json'; import * as LibSignatureValidator from '../generated-artifacts/LibSignatureValidator.json';
import * as LibStakingRichErrors from '../generated-artifacts/LibStakingRichErrors.json';
import * as MixinConstants from '../generated-artifacts/MixinConstants.json'; import * as MixinConstants from '../generated-artifacts/MixinConstants.json';
import * as MixinDelegatedStake from '../generated-artifacts/MixinDelegatedStake.json'; import * as MixinDelegatedStake from '../generated-artifacts/MixinDelegatedStake.json';
import * as MixinDeploymentConstants from '../generated-artifacts/MixinDeploymentConstants.json'; import * as MixinDeploymentConstants from '../generated-artifacts/MixinDeploymentConstants.json';
@ -64,6 +65,7 @@ export const artifacts = {
LibSafeMath64: LibSafeMath64 as ContractArtifact, LibSafeMath64: LibSafeMath64 as ContractArtifact,
LibSafeMath96: LibSafeMath96 as ContractArtifact, LibSafeMath96: LibSafeMath96 as ContractArtifact,
LibSignatureValidator: LibSignatureValidator as ContractArtifact, LibSignatureValidator: LibSignatureValidator as ContractArtifact,
LibStakingRichErrors: LibStakingRichErrors as ContractArtifact,
MixinDelegatedStake: MixinDelegatedStake as ContractArtifact, MixinDelegatedStake: MixinDelegatedStake as ContractArtifact,
MixinStake: MixinStake as ContractArtifact, MixinStake: MixinStake as ContractArtifact,
MixinStakeBalances: MixinStakeBalances as ContractArtifact, MixinStakeBalances: MixinStakeBalances as ContractArtifact,

View File

@ -19,6 +19,7 @@ export * from '../generated-wrappers/lib_safe_math';
export * from '../generated-wrappers/lib_safe_math64'; export * from '../generated-wrappers/lib_safe_math64';
export * from '../generated-wrappers/lib_safe_math96'; export * from '../generated-wrappers/lib_safe_math96';
export * from '../generated-wrappers/lib_signature_validator'; export * from '../generated-wrappers/lib_signature_validator';
export * from '../generated-wrappers/lib_staking_rich_errors';
export * from '../generated-wrappers/mixin_constants'; export * from '../generated-wrappers/mixin_constants';
export * from '../generated-wrappers/mixin_delegated_stake'; export * from '../generated-wrappers/mixin_delegated_stake';
export * from '../generated-wrappers/mixin_deployment_constants'; export * from '../generated-wrappers/mixin_deployment_constants';

View File

@ -660,7 +660,7 @@ export class StakingWrapper {
public async rewardVaultEnterCatastrophicFailureModeAsync( public async rewardVaultEnterCatastrophicFailureModeAsync(
zeroExMultisigAddress: string, zeroExMultisigAddress: string,
): Promise<TransactionReceiptWithDecodedLogs> { ): Promise<TransactionReceiptWithDecodedLogs> {
const calldata = this.getStakingPoolRewardVaultContract().enterCatostrophicFailure.getABIEncodedTransactionData(); const calldata = this.getStakingPoolRewardVaultContract().enterCatastrophicFailure.getABIEncodedTransactionData();
const txReceipt = await this._executeTransactionAsync(calldata, zeroExMultisigAddress); const txReceipt = await this._executeTransactionAsync(calldata, zeroExMultisigAddress);
return txReceipt; return txReceipt;
} }

View File

@ -19,6 +19,7 @@
"generated-artifacts/LibSafeMath64.json", "generated-artifacts/LibSafeMath64.json",
"generated-artifacts/LibSafeMath96.json", "generated-artifacts/LibSafeMath96.json",
"generated-artifacts/LibSignatureValidator.json", "generated-artifacts/LibSignatureValidator.json",
"generated-artifacts/LibStakingRichErrors.json",
"generated-artifacts/MixinConstants.json", "generated-artifacts/MixinConstants.json",
"generated-artifacts/MixinDelegatedStake.json", "generated-artifacts/MixinDelegatedStake.json",
"generated-artifacts/MixinDeploymentConstants.json", "generated-artifacts/MixinDeploymentConstants.json",