Take spans on stream completion
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
dbd7a6f369
commit
6f4c9b3bf9
11
src/lib.rs
11
src/lib.rs
|
@ -258,7 +258,16 @@ where
|
|||
|
||||
let body = this.body;
|
||||
|
||||
span.in_scope(|| dummy_span.in_scope(|| body.poll_next(cx)))
|
||||
let res = span.in_scope(|| dummy_span.in_scope(|| body.poll_next(cx)));
|
||||
|
||||
match res {
|
||||
Poll::Ready(None) => {
|
||||
this.span.take();
|
||||
this.dummy_span.take();
|
||||
Poll::Ready(None)
|
||||
}
|
||||
otherwise => otherwise,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue