Skip to content

Commit

Permalink
chore: use discovery function
Browse files Browse the repository at this point in the history
  • Loading branch information
dariusc93 committed Dec 1, 2024
1 parent abe126d commit db3186e
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions extensions/warp-ipfs/src/store/discovery.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ impl Discovery {
let executor = LocalExecutor;
let (command_tx, command_rx) = futures::channel::mpsc::channel(0);
let (broadcast_tx, _) = broadcast::channel(2048);
let task = DiscoveryTask::new(
let mut task = DiscoveryTask::new(
ipfs,
keypair,
command_rx,
Expand All @@ -59,6 +59,9 @@ impl Discovery {
relays.to_vec(),
)
.await;

task.discovery(None);

let _handle = executor.spawn_abortable(task);
Self {
command_tx,
Expand Down Expand Up @@ -611,7 +614,6 @@ impl DiscoveryTask {
}

// TODO: show that we are registered so we dont repeat multiple registration to the namespace when discovering peers

let ipfs = self.ipfs.clone();
let fut = async move {
ipfs.rendezvous_register_namespace(&namespace, None, rz_peer_id)
Expand Down

0 comments on commit db3186e

Please sign in to comment.