mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-14 06:21:11 +00:00
@@ -44,7 +44,7 @@ pub mod approval;
|
||||
/// it gives access to the commitments to validators who have not executed the candidate. This
|
||||
/// is necessary to allow a block-producing validator to include candidates from outside of the para
|
||||
/// it is assigned to.
|
||||
#[derive(Debug, Clone, PartialEq, Eq, Encode, Decode)]
|
||||
#[derive(Clone, PartialEq, Eq, Encode, Decode)]
|
||||
pub enum Statement {
|
||||
/// A statement that a validator seconds a candidate.
|
||||
#[codec(index = 1)]
|
||||
@@ -54,6 +54,15 @@ pub enum Statement {
|
||||
Valid(CandidateHash),
|
||||
}
|
||||
|
||||
impl std::fmt::Debug for Statement {
|
||||
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
||||
match self {
|
||||
Statement::Seconded(seconded) => write!(f, "Seconded: {:?}", seconded.descriptor),
|
||||
Statement::Valid(hash) => write!(f, "Valid: {:?}", hash),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl Statement {
|
||||
/// Get the candidate hash referenced by this statement.
|
||||
///
|
||||
|
||||
Reference in New Issue
Block a user