Skip to content

Commit

Permalink
Defend against ref being undefined
Browse files Browse the repository at this point in the history
  • Loading branch information
szegedi committed Oct 28, 2024
1 parent a872175 commit ebe4841
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/dd-trace/src/profiling/profilers/wall.js
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,8 @@ class NativeWallProfiler {

const labels = { ...getThreadLabels() }

const { context: { ref: { spanId, rootSpanId, webTags, endpoint } }, timestamp } = context
const { context: { ref }, timestamp } = context
const { spanId, rootSpanId, webTags, endpoint } = ref ?? {}

if (this._timelineEnabled) {
// Incoming timestamps are in microseconds, we emit nanos.
Expand Down

0 comments on commit ebe4841

Please sign in to comment.