Skip to content

Commit 38de2ed

Browse files
committed
fix debug id usage
1 parent e0c3985 commit 38de2ed

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

packages/shared/pkg/telemetry/tracing.go

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,11 @@ var OTELTracingPrint = os.Getenv("OTEL_TRACING_PRINT") != "false"
1616
const DebugID = "debug_id"
1717

1818
func getDebugID(ctx context.Context) *string {
19-
debugID, _ := ctx.Value(DebugID).(string)
19+
debugID, ok := ctx.Value(DebugID).(string)
20+
if !ok {
21+
return nil
22+
}
23+
2024
return &debugID
2125
}
2226

0 commit comments

Comments
 (0)