Skip to content

Commit

Permalink
feat(consensus): add From<ConsolidationRequest> for Request (allo…
Browse files Browse the repository at this point in the history
…y-rs#1083)

consensus: add From<ConsolidationRequest> for Request
  • Loading branch information
tcoratger authored and ben186 committed Jul 27, 2024
1 parent 43172ed commit a8c9fb8
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions crates/consensus/src/request.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,12 @@ impl From<WithdrawalRequest> for Request {
}
}

impl From<ConsolidationRequest> for Request {
fn from(v: ConsolidationRequest) -> Self {
Self::ConsolidationRequest(v)
}
}

impl Request {
/// Whether this is a [`DepositRequest`].
pub const fn is_deposit_request(&self) -> bool {
Expand Down

0 comments on commit a8c9fb8

Please sign in to comment.