Skip to content

Commit

Permalink
fix: use clone instead of to_owned
Browse files Browse the repository at this point in the history
  • Loading branch information
fundon committed Sep 27, 2024
1 parent 3400440 commit 7645adf
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions viz-core/src/middleware/otel/tracing.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ where
TracingMiddleware {
h,
tracer: self.tracer.clone(),
name: self.name.to_owned().unwrap_or("tracing".to_string()),
name: self.name.clone().unwrap_or("tracing".to_string()),
}
}
}
Expand Down Expand Up @@ -80,7 +80,7 @@ where
let attributes = build_attributes(&req, http_route.as_str());
let tracer = self
.tracer
.tracer_builder(self.name.to_owned())
.tracer_builder(self.name.clone())
.with_attributes(attributes)
.build();
let mut span = tracer.build_with_context(
Expand Down

0 comments on commit 7645adf

Please sign in to comment.