mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 10:59:55 +00:00
fix: fix tx propagation when full (#10251)
This commit is contained in:
@ -718,7 +718,7 @@ impl PoolTransaction for MockTransaction {
|
||||
|
||||
/// Returns the encoded length of the transaction.
|
||||
fn encoded_length(&self) -> usize {
|
||||
0
|
||||
self.size()
|
||||
}
|
||||
|
||||
/// Returns the chain ID associated with the transaction.
|
||||
|
||||
@ -499,6 +499,16 @@ impl PropagateKind {
|
||||
Self::Full(peer) | Self::Hash(peer) => peer,
|
||||
}
|
||||
}
|
||||
|
||||
/// Returns true if the transaction was sent as a full transaction
|
||||
pub const fn is_full(&self) -> bool {
|
||||
matches!(self, Self::Full(_))
|
||||
}
|
||||
|
||||
/// Returns true if the transaction was sent as a hash
|
||||
pub const fn is_hash(&self) -> bool {
|
||||
matches!(self, Self::Hash(_))
|
||||
}
|
||||
}
|
||||
|
||||
impl From<PropagateKind> for PeerId {
|
||||
|
||||
Reference in New Issue
Block a user