Skip to content

Commit

Permalink
fix: use main header id not pruning point as the tips
Browse files Browse the repository at this point in the history
  • Loading branch information
jackzhhuang committed Oct 9, 2024
1 parent 9b586b0 commit 68c433f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions sync/src/block_connector/write_block_chain.rs
Original file line number Diff line number Diff line change
Expand Up @@ -417,20 +417,20 @@ where
self.main.dag().save_dag_state(
genesis,
DagState {
tips: vec![new_head_block.header().pruning_point()],
tips: vec![new_head_block.header().id()],
},
)?;
self.main.dag().save_dag_state(
HashValue::zero(),
DagState {
tips: vec![new_head_block.header().pruning_point()],
tips: vec![new_head_block.header().id()],
},
)?;
} else {
self.main.dag().save_dag_state(
new_head_block.header().pruning_point(),
DagState {
tips: vec![new_head_block.header().pruning_point()],
tips: vec![new_head_block.header().id()],
},
)?;
}
Expand Down

0 comments on commit 68c433f

Please sign in to comment.