mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-31 11:01:01 +00:00
Remove deprecated code from bridge-runtime-common (#1983)
* removed FromBridgedChainMessageDispatch in favor of XcmBlobMessageDispatch * use HaulBlobExporter/HaulBlobExporterAdapter instead of XcmBridge/XcmBridgeAdapter * tests for sending/dispatching messages * use new schema in testnet bridges + some cleanup * clippy * spelling + added TODO * cleanup some checks * benchmarks compilation * all is XCM * updated README.md * ref issue from TODO
This commit is contained in:
committed by
Bastian Köcher
parent
2407228972
commit
a75c28d5b2
@@ -75,10 +75,7 @@ where
|
||||
let source_sign = data.source_sign.to_keypair::<Self::Source>()?;
|
||||
|
||||
let payload_len = payload.encoded_size();
|
||||
let send_message_call = Self::Source::encode_send_xcm(
|
||||
decode_xcm(payload)?,
|
||||
data.bridge.bridge_instance_index(),
|
||||
)?;
|
||||
let send_message_call = Self::Source::encode_execute_xcm(decode_xcm(payload)?)?;
|
||||
|
||||
source_client
|
||||
.submit_signed_extrinsic(&source_sign, move |_, transaction_nonce| {
|
||||
@@ -130,7 +127,7 @@ impl SendMessage {
|
||||
}
|
||||
|
||||
/// Decode SCALE encoded raw XCM message.
|
||||
pub(crate) fn decode_xcm(message: RawMessage) -> anyhow::Result<xcm::VersionedXcm<()>> {
|
||||
pub(crate) fn decode_xcm<Call>(message: RawMessage) -> anyhow::Result<xcm::VersionedXcm<Call>> {
|
||||
Decode::decode(&mut &message[..])
|
||||
.map_err(|e| anyhow::format_err!("Failed to decode XCM program: {:?}", e))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user