cuprate_blockchain::ops::tx

Function tx_exists

Source
pub fn tx_exists(
    tx_hash: &TxHash,
    table_tx_ids: &impl DatabaseRo<TxIds>,
) -> Result<bool, RuntimeError>
Expand description

Check if a transaction exists in the database.

Returns true if it does, else false.

§Errors

This function returns RuntimeError::KeyNotFound if the input (if applicable) doesn’t exist or other RuntimeError’s on database errors.