From f79bdcaaf0f9a497660b8a584dcad26cadddef03 Mon Sep 17 00:00:00 2001 From: Jun Kimura Date: Thu, 14 Dec 2023 22:56:00 +0900 Subject: [PATCH] fix lint warnings Signed-off-by: Jun Kimura --- modules/commitments/src/message.rs | 4 ++-- modules/commitments/src/message/verify_membership.rs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/commitments/src/message.rs b/modules/commitments/src/message.rs index 218ed145..e991954e 100644 --- a/modules/commitments/src/message.rs +++ b/modules/commitments/src/message.rs @@ -41,8 +41,8 @@ impl Message { pub fn commitment_type(&self) -> u16 { match self { - &Message::UpdateClient(_) => MESSAGE_TYPE_UPDATE_CLIENT, - &Message::VerifyMembership(_) => MESSAGE_TYPE_STATE, + Message::UpdateClient(_) => MESSAGE_TYPE_UPDATE_CLIENT, + Message::VerifyMembership(_) => MESSAGE_TYPE_STATE, } } } diff --git a/modules/commitments/src/message/verify_membership.rs b/modules/commitments/src/message/verify_membership.rs index 065eec15..0f005f3e 100644 --- a/modules/commitments/src/message/verify_membership.rs +++ b/modules/commitments/src/message/verify_membership.rs @@ -24,7 +24,7 @@ impl Display for VerifyMembershipMessage { "VerifyMembership(prefix: {:?}, path: {}, value: {}, height: {}, state_id: {})", self.prefix, self.path, - self.value.map_or("None".to_string(), |v| hex::encode(&v)), + self.value.map_or("None".to_string(), hex::encode), self.height, self.state_id, )