From c1ea6f6964e77db8e1fd1762e93c79c73cf7a542 Mon Sep 17 00:00:00 2001 From: Rostyslav Tyshko Date: Mon, 9 Dec 2024 03:59:53 +0100 Subject: [PATCH] RocksDBIO::new modification --- storage/src/lib.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/storage/src/lib.rs b/storage/src/lib.rs index 5a341a9..167e5d2 100644 --- a/storage/src/lib.rs +++ b/storage/src/lib.rs @@ -78,9 +78,12 @@ impl RocksDBIO { if is_start_set { Ok(dbio) } else if let Some(block) = start_block { + let block_id = block.block_id; dbio.put_meta_first_block_in_db(block)?; dbio.put_meta_is_first_block_set()?; + dbio.put_meta_last_block_in_db(block_id)?; + Ok(dbio) } else { warn!("Starting db in unset mode, will have to set starting block manually");