fix: check for genesis block on pool validator init (#7699)

This commit is contained in:
Matthias Seitz
2024-04-17 15:21:25 +02:00
committed by GitHub
parent 4911febe6f
commit dc39fd68f4
2 changed files with 13 additions and 3 deletions

View File

@ -26,6 +26,8 @@ const L1_BLOCK_ECOTONE_SELECTOR: [u8; 4] = hex!("440a5e20");
/// Extracts the [L1BlockInfo] from the L2 block. The L1 info transaction is always the first
/// transaction in the L2 block.
///
/// Returns an error if the L1 info transaction is not found, if the block is empty.
pub fn extract_l1_info(block: &Block) -> Result<L1BlockInfo, BlockExecutionError> {
let l1_info_tx_data = block
.body