From 016dd98bc49e9d6eada8d7884d5eda0a84119875 Mon Sep 17 00:00:00 2001 From: Branislav Kontur Date: Mon, 17 Oct 2022 11:51:08 +0200 Subject: [PATCH] Removed unused AccountId from `trait MessagesBridge` (#1600) --- bin/runtime-common/src/messages.rs | 1 - modules/messages/src/lib.rs | 8 ++------ primitives/messages/src/source_chain.rs | 6 +++--- 3 files changed, 5 insertions(+), 10 deletions(-) diff --git a/bin/runtime-common/src/messages.rs b/bin/runtime-common/src/messages.rs index 50944826ddeae..57f3f38cb2efb 100644 --- a/bin/runtime-common/src/messages.rs +++ b/bin/runtime-common/src/messages.rs @@ -532,7 +532,6 @@ pub mod source { /// Runtime message sender adapter. type MessageSender: bp_messages::source_chain::MessagesBridge< OriginOf>, - AccountIdOf>, BalanceOf>, FromThisChainMessagePayload, >; diff --git a/modules/messages/src/lib.rs b/modules/messages/src/lib.rs index 0580a0ffdfac5..962fd8f791578 100644 --- a/modules/messages/src/lib.rs +++ b/modules/messages/src/lib.rs @@ -775,12 +775,8 @@ pub mod pallet { } impl - bp_messages::source_chain::MessagesBridge< - T::Origin, - T::AccountId, - T::OutboundMessageFee, - T::OutboundPayload, - > for Pallet + bp_messages::source_chain::MessagesBridge + for Pallet where T: Config, I: 'static, diff --git a/primitives/messages/src/source_chain.rs b/primitives/messages/src/source_chain.rs index 5c6283a803602..70b52dc63aab8 100644 --- a/primitives/messages/src/source_chain.rs +++ b/primitives/messages/src/source_chain.rs @@ -182,7 +182,7 @@ pub struct SendMessageArtifacts { } /// Messages bridge API to be used from other pallets. -pub trait MessagesBridge { +pub trait MessagesBridge { /// Error type. type Error: Debug; @@ -201,8 +201,8 @@ pub trait MessagesBridge { #[derive(Eq, RuntimeDebug, PartialEq)] pub struct NoopMessagesBridge; -impl - MessagesBridge for NoopMessagesBridge +impl MessagesBridge + for NoopMessagesBridge { type Error = &'static str;