Skip to content

Commit

Permalink
make anycast generic
Browse files Browse the repository at this point in the history
  • Loading branch information
tweedegolf-marc committed Apr 30, 2024
1 parent e39c991 commit 43b3d36
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tsp/src/async_store.rs
Original file line number Diff line number Diff line change
Expand Up @@ -348,13 +348,13 @@ impl AsyncStore {
pub async fn send_anycast(
&self,
sender: &str,
receivers: &[&str],
receivers: impl IntoIterator<Item = impl AsRef<str>>,
nonconfidential_message: &[u8],
) -> Result<(), Error> {
let message = self.inner.sign_anycast(sender, nonconfidential_message)?;

for vid in receivers {
let receiver = self.inner.get_verified_vid(vid)?;
let receiver = self.inner.get_verified_vid(vid.as_ref())?;

crate::transport::send_message(receiver.endpoint(), &message).await?;
}
Expand Down

0 comments on commit 43b3d36

Please sign in to comment.