Merge branch 'master' into jg-transact-gas-warnings

This commit is contained in:
Jaco Greeff 2016-11-18 14:24:04 +01:00
commit bf58aab6a3
2 changed files with 10 additions and 0 deletions

View File

@ -48,6 +48,15 @@ export default class Status {
} }
this._store.dispatch(statusBlockNumber(blockNumber)); this._store.dispatch(statusBlockNumber(blockNumber));
this._api.eth
.getBlockByNumber(blockNumber)
.then((block) => {
this._store.dispatch(statusCollection({ gasLimit: block.gasLimit }));
})
.catch((error) => {
console.warn('status._subscribeBlockNumber', 'getBlockByNumber', error);
});
}) })
.then((subscriptionId) => { .then((subscriptionId) => {
console.log('status._subscribeBlockNumber', 'subscriptionId', subscriptionId); console.log('status._subscribeBlockNumber', 'subscriptionId', subscriptionId);

View File

@ -28,6 +28,7 @@ const initialState = {
enode: '', enode: '',
extraData: '', extraData: '',
gasFloorTarget: new BigNumber(0), gasFloorTarget: new BigNumber(0),
gasLimit: new BigNumber(0),
hashrate: new BigNumber(0), hashrate: new BigNumber(0),
minGasPrice: new BigNumber(0), minGasPrice: new BigNumber(0),
netChain: 'morden', netChain: 'morden',