From c63eca1e45ace284a07fd46582bbda7cee551680 Mon Sep 17 00:00:00 2001 From: whyrusleeping Date: Sun, 13 Oct 2019 09:41:24 +0900 Subject: [PATCH] if not needed License: MIT Signed-off-by: Jakub Sztandera --- chain/blocksync.go | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/chain/blocksync.go b/chain/blocksync.go index b2e65a9c2..50d24196a 100644 --- a/chain/blocksync.go +++ b/chain/blocksync.go @@ -123,12 +123,10 @@ func (bss *BlockSyncService) processRequest(ctx context.Context, req *BlockSyncR }, nil } - if span.IsRecordingEvents() { - span.AddAttributes( - trace.BoolAttribute("blocks", opts.IncludeBlocks), - trace.BoolAttribute("messages", opts.IncludeMessages), - ) - } + span.AddAttributes( + trace.BoolAttribute("blocks", opts.IncludeBlocks), + trace.BoolAttribute("messages", opts.IncludeMessages), + ) chain, err := bss.collectChainSegment(req.Start, req.RequestLength, opts) if err != nil {