From 8f60d6f8a10ed82a2e8ee01f9575422a80dfec7a Mon Sep 17 00:00:00 2001 From: Rob Date: Thu, 24 Oct 2024 16:36:18 -0400 Subject: [PATCH] unfill --- crates/types/src/data.rs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/crates/types/src/data.rs b/crates/types/src/data.rs index 3ea8566184..db891c8a0b 100644 --- a/crates/types/src/data.rs +++ b/crates/types/src/data.rs @@ -638,6 +638,11 @@ impl Leaf { Ok(()) } + /// Take the block payload from the leaf and return it if it is present + pub fn unfill_block_payload(&mut self) -> Option { + self.block_payload.take() + } + /// Fill this leaf with the block payload, without checking /// header and payload consistency pub fn fill_block_payload_unchecked(&mut self, block_payload: TYPES::BlockPayload) {