Skip to content
This repository has been archived by the owner on Feb 21, 2024. It is now read-only.

Commit

Permalink
Merge pull request paritytech#265 from subspace/fix-block-production
Browse files Browse the repository at this point in the history
Fix block production
  • Loading branch information
nazar-pc authored Feb 19, 2022
2 parents 1ed5e70 + 3d74096 commit d430466
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions crates/sc-consensus-subspace/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1182,11 +1182,13 @@ where
self.imported_block_notification_sender
.notify(move || (block_number, root_block_sender));

let root_blocks = root_block_receiver.collect().await;
let root_blocks: Vec<RootBlock> = root_block_receiver.collect().await;

self.root_blocks
.lock()
.put(block_number + One::one(), root_blocks);
if !root_blocks.is_empty() {
self.root_blocks
.lock()
.put(block_number + One::one(), root_blocks);
}

Ok(import_result)
}
Expand Down

0 comments on commit d430466

Please sign in to comment.