diff --git a/src/core/utils.ts b/src/core/utils.ts index fd474761..c934990f 100644 --- a/src/core/utils.ts +++ b/src/core/utils.ts @@ -159,7 +159,7 @@ export function getChartLegendItems(chart: Highcharts.Chart): readonly LegendIte } }; const addPointItem = (point: Highcharts.Point, isSecondary: boolean) => { - if (point.series.type === "pie") { + if (point?.series?.type === "pie") { legendItems.push({ id: getPointId(point), name: point.name,