diff --git a/substrate/core/client/src/client.rs b/substrate/core/client/src/client.rs index c008f0d157..6cf62dca2c 100644 --- a/substrate/core/client/src/client.rs +++ b/substrate/core/client/src/client.rs @@ -962,8 +962,8 @@ impl consensus::BlockImport for Client let ImportBlock { origin, header, - external_justification, - post_runtime_digests, + justification, + post_digests, body, finalized, .. @@ -975,11 +975,11 @@ impl consensus::BlockImport for Client blockchain::BlockStatus::Unknown => return Ok(ImportResult::UnknownParent), } - let import_headers = if post_runtime_digests.is_empty() { + let import_headers = if post_digests.is_empty() { PrePostHeader::Same(header) } else { let mut post_header = header.clone(); - for item in post_runtime_digests { + for item in post_digests { post_header.digest_mut().push(item); } PrePostHeader::Different(header, post_header) @@ -994,7 +994,7 @@ impl consensus::BlockImport for Client origin, hash, import_headers, - external_justification, + justification, body, new_authorities, finalized, diff --git a/substrate/core/consensus/aura/src/lib.rs b/substrate/core/consensus/aura/src/lib.rs index 6e993f1879..029fbe8025 100644 --- a/substrate/core/consensus/aura/src/lib.rs +++ b/substrate/core/consensus/aura/src/lib.rs @@ -240,8 +240,8 @@ pub fn start_aura( let import_block = ImportBlock { origin: BlockOrigin::Own, header, - external_justification: Vec::new(), - post_runtime_digests: vec![item], + justification: Vec::new(), + post_digests: vec![item], body: Some(body), finalized: false, auxiliary: Vec::new(), @@ -365,8 +365,8 @@ impl Verifier for AuraVerifier where let import_block = ImportBlock { origin, header: pre_header, - external_justification: Vec::new(), - post_runtime_digests: vec![item], + justification: Vec::new(), + post_digests: vec![item], body, finalized: false, auxiliary: Vec::new(), diff --git a/substrate/core/consensus/common/src/block_import.rs b/substrate/core/consensus/common/src/block_import.rs index 582886d827..566e5bfb02 100644 --- a/substrate/core/consensus/common/src/block_import.rs +++ b/substrate/core/consensus/common/src/block_import.rs @@ -44,7 +44,7 @@ pub struct ImportBlock { /// /// Consensus engines which alter the header (by adding post-runtime digests) /// should strip those off in the initial verification process and pass them - /// via the `post_runtime_digests` field. During block authorship, they should + /// via the `post_digests` field. During block authorship, they should /// not be pushed to the header directly. /// /// The reason for this distinction is so the header can be directly @@ -52,10 +52,10 @@ pub struct ImportBlock { /// post-runtime digests are pushed back on after. pub header: Block::Header, /// Justification provided for this block from the outside:. - pub external_justification: Justification, + pub justification: Justification, /// Digest items that have been added after the runtime for external /// work, like a consensus signature. - pub post_runtime_digests: Vec>, + pub post_digests: Vec>, /// Block's body pub body: Option>, /// Is this block finalized already? @@ -82,8 +82,8 @@ impl ImportBlock { ( self.origin, self.header, - self.external_justification, - self.post_runtime_digests, + self.justification, + self.post_digests, self.body, self.finalized, self.auxiliary, diff --git a/substrate/core/consensus/rhd/src/lib.rs b/substrate/core/consensus/rhd/src/lib.rs index 4995592aaf..449f9c3ffa 100644 --- a/substrate/core/consensus/rhd/src/lib.rs +++ b/substrate/core/consensus/rhd/src/lib.rs @@ -417,10 +417,10 @@ impl Future for BftFuture Verifier for PassThroughVerifier { header, body, finalized: self.0, - external_justification: justification, - post_runtime_digests: vec![], + justification: justification, + post_digests: vec![], auxiliary: Vec::new(), }, None)) } diff --git a/substrate/core/test-client/src/client_ext.rs b/substrate/core/test-client/src/client_ext.rs index f16bfce40f..d0a8765255 100644 --- a/substrate/core/test-client/src/client_ext.rs +++ b/substrate/core/test-client/src/client_ext.rs @@ -47,8 +47,8 @@ impl TestClient for Client let import = ImportBlock { origin, header: block.header, - external_justification: vec![], - post_runtime_digests: vec![], + justification: vec![], + post_digests: vec![], body: Some(block.extrinsics), finalized: false, auxiliary: Vec::new(), diff --git a/substrate/node/cli/src/service.rs b/substrate/node/cli/src/service.rs index 820c1dee26..5a5edb89b0 100644 --- a/substrate/node/cli/src/service.rs +++ b/substrate/node/cli/src/service.rs @@ -124,7 +124,7 @@ mod tests { let block = proposer.propose().expect("Error making test block"); ImportBlock { origin: BlockOrigin::File, - external_justification: Vec::new(), + justification: Vec::new(), internal_justification: Vec::new(), finalized: true, body: Some(block.extrinsics),