Skip to content

Commit

Permalink
cleanup relayer storage xdm keys for the relayer
Browse files Browse the repository at this point in the history
  • Loading branch information
vedhavyas committed Dec 11, 2024
1 parent 3ccf78c commit 2a96cfb
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions domains/client/cross-domain-message-gossip/src/aux_schema.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
//! Schema for channel update storage.
use crate::RELAYER_PREFIX;
use parity_scale_codec::{Decode, Encode};
use sc_client_api::backend::AuxStore;
use sp_blockchain::{Error as ClientError, Info, Result as ClientResult};
Expand Down Expand Up @@ -88,6 +89,19 @@ where
channel_detail.encode().as_slice(),
)],
vec![],
)?;

let channel_nonce = ChannelNonce {
relay_msg_nonce: Some(channel_detail.next_inbox_nonce),
relay_response_msg_nonce: channel_detail.latest_response_received_message_nonce,
};
let prefix = (RELAYER_PREFIX, src_chain_id).encode();
cleanup_chain_channel_storages(
backend,
&prefix,
src_chain_id,
channel_detail.channel_id,
channel_nonce,
)
}

Expand Down

0 comments on commit 2a96cfb

Please sign in to comment.