From 18eab816287ccd3d945bddcf1cf0a39c20caa1d8 Mon Sep 17 00:00:00 2001 From: Pratik Mankawde <3397372+pratikmankawde@users.noreply.github.com> Date: Thu, 23 Jul 2026 14:09:18 +0100 Subject: [PATCH] refactor(telemetry): use activateIfLive helper at ledger.acquire site Co-Authored-By: Claude Opus 4.8 (1M context) --- src/xrpld/app/ledger/detail/InboundLedger.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/xrpld/app/ledger/detail/InboundLedger.cpp b/src/xrpld/app/ledger/detail/InboundLedger.cpp index 2b47f92244..de2c3d6c27 100644 --- a/src/xrpld/app/ledger/detail/InboundLedger.cpp +++ b/src/xrpld/app/ledger/detail/InboundLedger.cpp @@ -459,8 +459,7 @@ InboundLedger::done() // activation pops at the end of this block (restoring the prior context) // while acquireSpan_ is still alive, then reset() ends the span. { - auto acquireActivation = (acquireSpan_ && *acquireSpan_) ? acquireSpan_->activate() - : telemetry::ScopedActivation{}; + auto acquireActivation = telemetry::activateIfLive(acquireSpan_); if (acquireSpan_ && *acquireSpan_) { using namespace telemetry;