diff --git a/query-engine/query-engine/src/logger.rs b/query-engine/query-engine/src/logger.rs index 73fe93c1518a..aaf03e7f3e3f 100644 --- a/query-engine/query-engine/src/logger.rs +++ b/query-engine/query-engine/src/logger.rs @@ -87,8 +87,8 @@ impl<'a> Logger<'a> { let tracer = create_otel_tracer(self.service_name, self.telemetry_endpoint); let mut telemetry = tracing_opentelemetry::layer().with_tracer(tracer); - if self.log_capture_exporter.is_some() { - let tracer = crate::capture_tracer::new_pipeline().install_simple(self.log_capture_exporter.unwrap()); + if let Some(log_capture_exporter) = self.log_capture_exporter { + let tracer = crate::capture_tracer::new_pipeline().install_simple(log_capture_exporter); telemetry = telemetry.with_tracer(tracer); }