Skip to content

Commit e9ead03

Browse files
cephalizationmikeldking
authored andcommitted
fix(annotations): Safeguard against null spanAnnotationSummaries (#7403)
1 parent 24cc2b0 commit e9ead03

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

app/src/pages/project/TracesTable.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -373,7 +373,7 @@ export function TracesTable(props: TracesTableProps) {
373373
const annotation = (
374374
row.original
375375
.spanAnnotationSummaries as TracesTable_spans$data["rootSpans"]["edges"][number]["rootSpan"]["spanAnnotationSummaries"]
376-
).find((annotation) => annotation.name === name);
376+
)?.find((annotation) => annotation.name === name);
377377
if (!annotation) {
378378
return null;
379379
}
@@ -392,7 +392,7 @@ export function TracesTable(props: TracesTableProps) {
392392
const annotation = (
393393
row.original
394394
.spanAnnotationSummaries as TracesTable_spans$data["rootSpans"]["edges"][number]["rootSpan"]["spanAnnotationSummaries"]
395-
).find((annotation) => annotation.name === name);
395+
)?.find((annotation) => annotation.name === name);
396396
if (!annotation) {
397397
return null;
398398
}

0 commit comments

Comments
 (0)