indexer: fixed Fjalls rollback

This commit is contained in:
nym21
2025-02-24 18:15:13 +01:00
parent 53175c9ed7
commit 01ecae8979
8 changed files with 108 additions and 104 deletions
+5 -2
View File
@@ -191,7 +191,6 @@ impl Parser {
}
let height = Height::from(header.height);
// println!("{height}");
let len = blk_index_to_blk_recap.tree.len();
if blk_metadata.index == len as u16 || blk_metadata.index + 1 == len as u16 {
@@ -235,9 +234,13 @@ impl Parser {
None
}
}) {
if end.is_some_and(|end| end < current_height) {
return ControlFlow::Break(());
}
send_height_block_hash.send((current_height, block, hash)).unwrap();
if end == Some(current_height) {
if end.is_some_and(|end| end == current_height) {
return ControlFlow::Break(());
}