mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 19:09:54 +00:00
Implement From<Block> for BlockBody (#7643)
This commit is contained in:
@ -604,6 +604,12 @@ impl BlockBody {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
impl From<Block> for BlockBody {
|
||||||
|
fn from(block: Block) -> Self {
|
||||||
|
Self { transactions: block.body, ommers: block.ommers, withdrawals: block.withdrawals }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod tests {
|
mod tests {
|
||||||
use super::{BlockNumberOrTag::*, *};
|
use super::{BlockNumberOrTag::*, *};
|
||||||
|
|||||||
Reference in New Issue
Block a user