From 30a5cb6d007154060aae94c7759e01c4658ebcb9 Mon Sep 17 00:00:00 2001 From: NicolasFlamel1 Date: Thu, 14 Jul 2022 23:09:32 -0700 Subject: [PATCH] Fixes calculating total number of coinbase rewards at the last block reward --- core/src/consensus.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/consensus.rs b/core/src/consensus.rs index f0f90f40b5..daefa6619a 100644 --- a/core/src/consensus.rs +++ b/core/src/consensus.rs @@ -627,7 +627,7 @@ pub fn calc_mwc_block_overage(height: u64, genesis_had_reward: bool) -> u64 { overage += get_epoch_reward(11) * (get_epoch_duration(11)); // we add the last block reward to get us to 20 million - if height > get_epoch_block_offset(11) + get_epoch_duration(11) { + if height >= get_epoch_block_offset(11) + get_epoch_duration(11) { overage += get_epoch_reward(12); }