diff --git a/src/observability.rs b/src/observability.rs index e1e681ef..5e9f2d2d 100644 --- a/src/observability.rs +++ b/src/observability.rs @@ -55,7 +55,7 @@ pub(crate) enum FoundIn { impl FoundIn { /// Returns a stringified representation of the current value - fn value(&self) -> &'static str { + fn as_str(&self) -> &'static str { match self { FoundIn::Cache => "hit", FoundIn::Database => "miss-database", @@ -67,7 +67,7 @@ impl FoundIn { /// Record the current value to the current [`tracing::Span`] // TODO: use tracing::Value instead if it ever becomes accessible pub(crate) fn record(&self, field: &str) { - tracing::Span::current().record(field, self.value()); + tracing::Span::current().record(field, self.as_str()); } }