Use ThreadPool's impl of spawn (#1139)

This commit is contained in:
yanjhk
2019-06-10 11:23:12 -07:00
committed by Carl Lerche
parent 41ca9a43de
commit 5c0b56278b
+1 -1
View File
@@ -234,7 +234,7 @@ impl Runtime {
pub fn spawn<F>(&mut self, future: F) -> &mut Self
where F: Future<Item = (), Error = ()> + Send + 'static,
{
self.inner_mut().pool.sender().spawn(future).unwrap();
self.inner_mut().pool.spawn(future);
self
}