Use enclosing transaction within scheduler::optimistic::run_one rather than opening a new one.

This commit is contained in:
Colin LeMahieu 2024-04-11 15:24:53 +01:00
commit 2ac4aa79d8
No known key found for this signature in database
GPG key ID: 43708520C8DFB938

View file

@ -155,7 +155,7 @@ void nano::scheduler::optimistic::run_one (store::transaction const & transactio
if (block)
{
// Ensure block is not already confirmed
if (!node.block_confirmed_or_being_confirmed (block->hash ()))
if (!node.block_confirmed_or_being_confirmed (transaction, block->hash ()))
{
// Try to insert it into AEC
// We check for AEC vacancy inside our predicate