Skip to content

Commit

Permalink
chore: add SealedHeader::split (paradigmxyz#2763)
Browse files Browse the repository at this point in the history
  • Loading branch information
mattsse authored May 22, 2023
1 parent b2c5f33 commit 71581ab
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions crates/primitives/src/header.rs
Original file line number Diff line number Diff line change
Expand Up @@ -308,6 +308,11 @@ impl SealedHeader {
self.header
}

/// This is the inverse of [Header::seal_slow] which returns the raw header and hash.
pub fn split(self) -> (Header, BlockHash) {
(self.header, self.hash)
}

/// Return header/block hash.
pub fn hash(&self) -> BlockHash {
self.hash
Expand Down

0 comments on commit 71581ab

Please sign in to comment.