mirror of
https://github.com/grafana/grafana.git
synced 2026-07-29 15:59:50 -05:00
PieChart: Handle undefined custom.hideFrom in fieldConfig (#34185)
This commit is contained in:
@@ -76,7 +76,7 @@ function getLegend(props: Props, displayValues: FieldDisplay[]) {
|
||||
}
|
||||
const total = displayValues
|
||||
.filter((item) => {
|
||||
return !item.field.custom.hideFrom.viz;
|
||||
return !item.field.custom?.hideFrom?.viz;
|
||||
})
|
||||
.reduce((acc, item) => item.display.numeric + acc, 0);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user