Skip to content

Commit 2a96cfb

Browse files
committed
cleanup relayer storage xdm keys for the relayer
1 parent 3ccf78c commit 2a96cfb

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

domains/client/cross-domain-message-gossip/src/aux_schema.rs

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
//! Schema for channel update storage.
22
3+
use crate::RELAYER_PREFIX;
34
use parity_scale_codec::{Decode, Encode};
45
use sc_client_api::backend::AuxStore;
56
use sp_blockchain::{Error as ClientError, Info, Result as ClientResult};
@@ -88,6 +89,19 @@ where
8889
channel_detail.encode().as_slice(),
8990
)],
9091
vec![],
92+
)?;
93+
94+
let channel_nonce = ChannelNonce {
95+
relay_msg_nonce: Some(channel_detail.next_inbox_nonce),
96+
relay_response_msg_nonce: channel_detail.latest_response_received_message_nonce,
97+
};
98+
let prefix = (RELAYER_PREFIX, src_chain_id).encode();
99+
cleanup_chain_channel_storages(
100+
backend,
101+
&prefix,
102+
src_chain_id,
103+
channel_detail.channel_id,
104+
channel_nonce,
91105
)
92106
}
93107

0 commit comments

Comments
 (0)