Repository URL to install this package:
|
Version:
0.7.0 ▾
|
// (c) Copyright 2023 Supertenant Ltd. - all rights reserved.
// See LICENSE file in project root for license terms.
"use strict";const currentSpanKey="com.supertenant.span",reducedSpanKey="com.supertenant.reduced";function storeReducedSpan(context,key,span){key===currentSpanKey&&null!=span&&(context[reducedSpanKey]={n:span.n,t:span.t,s:span.s,p:span.p,k:span.k},key=span.gqd)&&(context[reducedSpanKey].gqd=key)}module.exports=function(context,key,value){context[key]===value&&(storeReducedSpan(context,key,value),delete context[key])};