Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Commit

Permalink
Use to_poll on wasm
Browse files Browse the repository at this point in the history
  • Loading branch information
expenses committed Jan 15, 2020
1 parent 8da9a8a commit 1c61728
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions client/service/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,10 @@ impl<TBl, TCl, TSc, TNetStatus, TNet, TTxPool, TOc> Future for
}

while let Poll::Ready(Some(task_to_spawn)) = Pin::new(&mut this.to_spawn_rx).poll_next(cx) {
#[cfg(not(target_os = "unknown"))]
tokio::spawn(task_to_spawn);
#[cfg(target_os = "unknown")]
this.to_poll.push(task_to_spawn);
}

// Polling all the `to_poll` futures.
Expand Down

0 comments on commit 1c61728

Please sign in to comment.