File tree Expand file tree Collapse file tree 2 files changed +4
-11
lines changed
tracing-subscriber/src/registry Expand file tree Collapse file tree 2 files changed +4
-11
lines changed Original file line number Diff line number Diff line change @@ -287,21 +287,15 @@ impl Collect for Registry {
287287 fn event ( & self , _: & Event < ' _ > ) { }
288288
289289 fn enter ( & self , id : & span:: Id ) {
290- if self
291- . current_spans
290+ self . current_spans
292291 . get_or_default ( )
293292 . borrow_mut ( )
294- . push ( id. clone ( ) )
295- {
296- self . clone_span ( id) ;
297- }
293+ . push ( id. clone ( ) ) ;
298294 }
299295
300296 fn exit ( & self , id : & span:: Id ) {
301297 if let Some ( spans) = self . current_spans . get ( ) {
302- if spans. borrow_mut ( ) . pop ( id) {
303- dispatch:: get_default ( |dispatch| dispatch. try_close ( id. clone ( ) ) ) ;
304- }
298+ spans. borrow_mut ( ) . pop ( id) ;
305299 }
306300 }
307301
Original file line number Diff line number Diff line change @@ -17,10 +17,9 @@ pub(crate) struct SpanStack {
1717
1818impl SpanStack {
1919 #[ inline]
20- pub ( super ) fn push ( & mut self , id : Id ) -> bool {
20+ pub ( super ) fn push ( & mut self , id : Id ) {
2121 let duplicate = self . stack . iter ( ) . any ( |i| i. id == id) ;
2222 self . stack . push ( ContextId { id, duplicate } ) ;
23- !duplicate
2423 }
2524
2625 #[ inline]
You can’t perform that action at this time.
0 commit comments