Skip to content

Commit 2d370d2

Browse files
authored
Merge branch 'master' into minor
2 parents cc3002c + f2687e9 commit 2d370d2

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/rpc/pd/leader.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -119,12 +119,11 @@ impl PdReactor {
119119
let mut core = Core::new().unwrap();
120120
let handle = core.handle();
121121
{
122-
let f = rx.take_while(|t| ready(t.is_some())).then(|t| {
122+
let f = rx.take_while(|t| ready(t.is_some())).for_each(|t| {
123123
Self::dispatch(&client, t.unwrap(), &handle);
124124
ready(())
125125
});
126-
core.run(TryFutureExt::compat(f.into_future().unit_error()))
127-
.unwrap();
126+
core.run(TryFutureExt::compat(f.unit_error())).unwrap();
128127
}
129128
}
130129

0 commit comments

Comments
 (0)