Fix warp sync (#12281)

This commit is contained in:
Arkadiy Paronyan
2022-09-16 16:16:37 +02:00
committed by GitHub
parent d9a4d835d1
commit 86b122d7a7
4 changed files with 50 additions and 33 deletions
+11 -9
View File
@@ -341,15 +341,17 @@ where
if let Some(inner_body) = block.body.take() {
let check_block = B::new(block.header.clone(), inner_body);
self.check_inherents(
check_block.clone(),
BlockId::Hash(parent_hash),
self.create_inherent_data_providers
.create_inherent_data_providers(parent_hash, ())
.await?,
block.origin.into(),
)
.await?;
if !block.state_action.skip_execution_checks() {
self.check_inherents(
check_block.clone(),
BlockId::Hash(parent_hash),
self.create_inherent_data_providers
.create_inherent_data_providers(parent_hash, ())
.await?,
block.origin.into(),
)
.await?;
}
block.body = Some(check_block.deconstruct().1);
}