Use Blockstore lowest_slot to start root iterator (#9738)

This commit is contained in:
Tyera Eulberg
2020-04-28 10:22:10 -06:00
committed by GitHub
parent 3d8fc8a4a8
commit a12428a5b8
2 changed files with 6 additions and 5 deletions

View File

@@ -1502,7 +1502,7 @@ impl Blockstore {
}
pub fn get_first_available_block(&self) -> Result<Slot> {
let mut root_iterator = self.rooted_slot_iterator(0)?;
let mut root_iterator = self.rooted_slot_iterator(self.lowest_slot())?;
Ok(root_iterator.next().unwrap_or_default())
}