UNPKG

bitcore-node

Version:

A blockchain indexing node with extended capabilities using bitcore

24 lines 694 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.EthP2pWorker = void 0; const p2p_1 = require("../../../providers/chain-state/evm/p2p/p2p"); class EthP2pWorker extends p2p_1.EVMP2pWorker { getBlockReward(block) { let reward = 5; const height = block.number; const ForkHeights = { Byzantium: 4370000, Constantinople: 7280000 }; if (height > ForkHeights.Constantinople) { reward = 2; } else if (height > ForkHeights.Byzantium) { reward = 3; } return reward; } } exports.EthP2pWorker = EthP2pWorker; ; //# sourceMappingURL=p2p.js.map