mirror of
https://github.com/chatmail/core.git
synced 2026-05-20 23:36:30 +03:00
keep lock longer
This commit is contained in:
@@ -90,6 +90,7 @@ impl Iroh {
|
|||||||
0
|
0
|
||||||
};
|
};
|
||||||
|
|
||||||
|
let mut channels = self.iroh_channels.write().await;
|
||||||
let peers = get_iroh_gossip_peers(ctx, msg_id).await?;
|
let peers = get_iroh_gossip_peers(ctx, msg_id).await?;
|
||||||
info!(
|
info!(
|
||||||
ctx,
|
ctx,
|
||||||
@@ -115,10 +116,7 @@ impl Iroh {
|
|||||||
.join(topic, peers.into_iter().map(|addr| addr.node_id).collect())
|
.join(topic, peers.into_iter().map(|addr| addr.node_id).collect())
|
||||||
.await?;
|
.await?;
|
||||||
|
|
||||||
self.iroh_channels
|
channels.insert(topic, ChannelState::new(seq, subscribe_loop));
|
||||||
.write()
|
|
||||||
.await
|
|
||||||
.insert(topic, ChannelState::new(seq, subscribe_loop));
|
|
||||||
|
|
||||||
Ok(Some(connect_future))
|
Ok(Some(connect_future))
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user