From 74221dfb3fef44b1ad3ab2d0d4c13ae139a1a88e Mon Sep 17 00:00:00 2001 From: Stuart Woodbury Date: Thu, 9 Nov 2023 16:39:13 -0500 Subject: [PATCH] fix fmt --- .../src/blink_impl/gossipsub_sender.rs | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/extensions/warp-blink-wrtc/src/blink_impl/gossipsub_sender.rs b/extensions/warp-blink-wrtc/src/blink_impl/gossipsub_sender.rs index 55eb2daa7..adf66fdf6 100644 --- a/extensions/warp-blink-wrtc/src/blink_impl/gossipsub_sender.rs +++ b/extensions/warp-blink-wrtc/src/blink_impl/gossipsub_sender.rs @@ -272,17 +272,17 @@ async fn run( }, GossipSubCmd::SendEcdh { dest, signal, topic } => { // only add to the queue if sending fails - let encrypted = match ecdh_encrypt(&own_id, &dest, signal.clone()) { - Ok(r) => r, - Err(e) => { - log::error!("failed to encrypt ecdh message: {e}"); - continue; - } - }; - if ipfs.pubsub_publish(topic.clone(), encrypted).await.is_err() { - let queue = ecdh_queue.entry(dest.clone()).or_default(); - queue.push_back(GossipSubCmd::SendEcdh { dest, signal, topic }); + let encrypted = match ecdh_encrypt(&own_id, &dest, signal.clone()) { + Ok(r) => r, + Err(e) => { + log::error!("failed to encrypt ecdh message: {e}"); + continue; } + }; + if ipfs.pubsub_publish(topic.clone(), encrypted).await.is_err() { + let queue = ecdh_queue.entry(dest.clone()).or_default(); + queue.push_back(GossipSubCmd::SendEcdh { dest, signal, topic }); + } } GossipSubCmd::Announce { group_key, signal, topic } => { let encrypted = match Cipher::direct_encrypt(&signal, &group_key) {