Skip to main content

add_alt_block

Function add_alt_block 

Source
pub fn add_alt_block(
    db: &BlockchainDatabase,
    alt_block: &AltBlockInformation,
    tx_rw: &mut OwnedWriteBatch,
) -> DbResult<()>
Expand description

Add a [AltBlockInformation] to the database.

This extracts all the data from the input block and maps/adds them to the appropriate database tables.

ยงPanics

This function may panic if the given block data is invalid.

THIS IS NOT ATOMIC