feat(primitives): add From<Sealed<B>> for SealedBlock<B> (#21078)

This commit is contained in:
Matthias Seitz
2026-01-14 23:19:09 +01:00
committed by GitHub
parent 1fbd5a95f8
commit 0a4bac77d0

View File

@@ -282,6 +282,13 @@ where
}
}
impl<B: Block> From<Sealed<B>> for SealedBlock<B> {
fn from(sealed: Sealed<B>) -> Self {
let (block, hash) = sealed.into_parts();
Self::new_unchecked(block, hash)
}
}
impl<B> Default for SealedBlock<B>
where
B: Block + Default,