Skip to content

Commit 42bcfe9

Browse files
committed
refactor: use BlockHash instead of byte array
1 parent d634386 commit 42bcfe9

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

dash/src/sml/llmq_entry_verification.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ use core::fmt::{Display, Formatter};
22

33
#[cfg(feature = "bincode")]
44
use bincode::{Decode, Encode};
5-
5+
use crate::BlockHash;
66
use crate::prelude::CoreBlockHeight;
77
use crate::sml::quorum_validation_error::QuorumValidationError;
88

@@ -13,7 +13,7 @@ use crate::sml::quorum_validation_error::QuorumValidationError;
1313
pub enum LLMQEntryVerificationSkipStatus {
1414
NotMarkedForVerification,
1515
MissedList(CoreBlockHeight),
16-
UnknownBlock([u8; 32]),
16+
UnknownBlock(BlockHash),
1717
OtherContext(String),
1818
}
1919

@@ -27,7 +27,7 @@ impl Display for LLMQEntryVerificationSkipStatus {
2727
format!("MissedList({})", block_height)
2828
}
2929
LLMQEntryVerificationSkipStatus::UnknownBlock(block_hash) => {
30-
format!("UnknownBlock({})", hex::encode(block_hash))
30+
format!("UnknownBlock({})", block_hash)
3131
}
3232
LLMQEntryVerificationSkipStatus::OtherContext(message) => {
3333
format!("OtherContext({message})")

dash/src/sml/quorum_entry/qualified_quorum_entry.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ impl QualifiedQuorumEntry {
5959
match result {
6060
Err(QuorumValidationError::RequiredBlockNotPresent(block_hash)) => {
6161
self.verified = LLMQEntryVerificationStatus::Skipped(
62-
LLMQEntryVerificationSkipStatus::UnknownBlock(block_hash.to_byte_array()),
62+
LLMQEntryVerificationSkipStatus::UnknownBlock(block_hash),
6363
);
6464
}
6565
Err(QuorumValidationError::RequiredMasternodeListNotPresent(block_height)) => {

0 commit comments

Comments
 (0)