decode call after spec_version check (#663)

This commit is contained in:
Svyatoslav Nikolsky
2021-01-27 09:22:17 +03:00
committed by Bastian Köcher
parent 44bf84269a
commit acee5580ca
7 changed files with 126 additions and 82 deletions
+2 -1
View File
@@ -215,6 +215,7 @@ impl pallet_bridge_call_dispatch::Config for Runtime {
type Event = Event;
type MessageId = (bp_message_lane::LaneId, bp_message_lane::MessageNonce);
type Call = Call;
type EncodedCall = crate::rialto_messages::FromRialtoEncodedCall;
type SourceChainAccountId = bp_rialto::AccountId;
type TargetChainAccountPublic = MultiSigner;
type TargetChainSignature = MultiSignature;
@@ -602,7 +603,7 @@ impl_runtime_apis! {
/// This way, the owner of `millau_account_id` on Millau proves that the Rialto account private key
/// is also under his control.
pub fn rialto_account_ownership_digest<Call, AccountId, SpecVersion>(
rialto_call: Call,
rialto_call: &Call,
millau_account_id: AccountId,
rialto_spec_version: SpecVersion,
) -> sp_std::vec::Vec<u8>
@@ -63,6 +63,9 @@ pub type ToRialtoMessageVerifier = messages::source::FromThisChainMessageVerifie
/// Message payload for Rialto -> Millau messages.
pub type FromRialtoMessagePayload = messages::target::FromBridgedChainMessagePayload<WithRialtoMessageBridge>;
/// Encoded Millau Call as it comes from Rialto.
pub type FromRialtoEncodedCall = messages::target::FromBridgedChainEncodedMessageCall<WithRialtoMessageBridge>;
/// Messages proof for Rialto -> Millau messages.
type FromRialtoMessagesProof = messages::target::FromBridgedChainMessagesProof<WithRialtoMessageBridge>;