Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump lodash from 4.17.10 to 4.17.15 #4

Closed
wants to merge 10 commits into from
9 changes: 9 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,15 @@ ARTIS specific changes were limited to the introduction of a collateral requirem
- [PoA Consensus Audit](https://github.com/poanetwork/poa-network-consensus-contracts/blob/master/audit/MixBytes/PoA%20Consensus%20Audit.pdf) by MixBytes
- [PoA Consensus Audit](https://github.com/poanetwork/poa-network-consensus-contracts/blob/master/audit/ChainSecurity/ChainSecurity_PoA.pdf) by ChainSecurity

## Run tests

Use node.js v8.

- `npm ci`
- `npm test`

The test script builds the contracts, starts an instance of [ganache-cli](https://github.com/trufflesuite/ganache-cli) in the background and then executes all tests (takes a while).

## Start a network

New networks are bootstrapped by a _Master of Ceremony_.
Expand Down
7 changes: 6 additions & 1 deletion contracts/ProxyStorage.sol
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,8 @@ contract ProxyStorage is EternalStorage, IProxyStorage {
BallotsStorage,
PoaConsensus,
ValidatorMetadata,
ProxyStorage
ProxyStorage,
RewardByBlock
}

event ProxyInitialized(
Expand Down Expand Up @@ -210,6 +211,10 @@ contract ProxyStorage is EternalStorage, IProxyStorage {
).upgradeTo(_contractAddress);
} else if (_contractType == uint256(ContractTypes.ProxyStorage)) {
success = IEternalStorageProxy(this).upgradeTo(_contractAddress);
} else if (_contractType == uint256(ContractTypes.RewardByBlock)) {
success = IEternalStorageProxy(
getRewardByBlock()
).upgradeTo(_contractAddress);
}
if (success) {
emit AddressSet(_contractType, _contractAddress);
Expand Down
7 changes: 6 additions & 1 deletion contracts/RewardByBlock.sol
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,11 @@ contract RewardByBlock is EternalStorage, IRewardByBlock {

address miningKey = benefactors[0];

if (miningKey == address(0)) {
// Return empty arrays
return (new address[](0), new uint256[](0));
}

require(_isMiningActive(miningKey));

uint256 extraLength = extraReceiversLength();
Expand Down Expand Up @@ -153,7 +158,7 @@ contract RewardByBlock is EternalStorage, IRewardByBlock {
}

function emissionFundsActivationTimestamp() public pure returns(uint) {
return 1573732800; // 14. Nov 2019
return (2^256)-1; // never
}

function bridgeAmount(address _bridge) public view returns(uint256) {
Expand Down
113 changes: 57 additions & 56 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading