Apply suggestions from code review

Co-authored-by: Daira Hopwood <daira@jacaranda.org>
This commit is contained in:
Kris Nuttycombe 2020-07-10 08:29:47 -06:00 committed by GitHub
parent 0e7ae06905
commit c88b461f89
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 2 deletions

View File

@ -181,13 +181,14 @@ public:
}
CAmount SetFoundersRewardAndGetMinerValue(void* ctx) const {
auto miner_reward = GetBlockSubsidy(nHeight, chainparams.GetConsensus());
auto block_subsidy = GetBlockSubsidy(nHeight, chainparams.GetConsensus());
auto miner_reward = block_subsidy; // founders' reward or funding stream amounts will be subtracted below
if (nHeight > 0) {
if (chainparams.GetConsensus().NetworkUpgradeActive(nHeight, Consensus::UPGRADE_CANOPY)) {
auto fundingStreamElements = Consensus::GetActiveFundingStreamElements(
nHeight,
miner_reward,
block_subsidy,
chainparams.GetConsensus());
for (Consensus::FundingStreamElement fselem : fundingStreamElements) {