diff --git a/pkg/ambient/ambient.go b/pkg/ambient/ambient.go index 4182f95..632a265 100644 --- a/pkg/ambient/ambient.go +++ b/pkg/ambient/ambient.go @@ -138,6 +138,8 @@ func (aw *AmbientWeather) enrichUpdate( // Calculate any fields that may be missing // such as dew point and wind chill ctx, enrichSpan := tracer.Start(ctx, p.Name()+".update.enrich") + defer enrichSpan.End() + update.Enrich() // Enrich station if configured @@ -147,7 +149,6 @@ func (aw *AmbientWeather) enrichUpdate( update.MapSensors() enrichSpan.SetStatus(codes.Ok, "") - enrichSpan.End() } func (aw *AmbientWeather) proxyUpdate(