Update beacon_node/beacon_chain/src/execution_payload.rs

Co-authored-by: Paul Hauner <paul@paulhauner.com>
This commit is contained in:
ethDreamer
2022-02-28 11:45:37 -06:00
committed by GitHub
parent 3e652b46a1
commit ba171ab556

View File

@@ -145,7 +145,7 @@ pub fn validate_merge_block<T: BeaconChainTypes>(
// the justified checkpoint can't have execution enabled so we only need to check the
// current slot is at least SAFE_SLOTS_TO_IMPORT_OPTIMISTICALLY ahead of the block
// https://github.com/ethereum/consensus-specs/blob/v1.1.9/sync/optimistic.md#when-to-optimistically-import-blocks
if current_slot - block.slot() >= chain.spec.safe_slots_to_import_optimistically {
if block.slot() + chain.spec.safe_slots_to_import_optimistically <= current_slot {
debug!(
chain.log,
"Optimistically accepting terminal block";