diff --git a/superset-frontend/src/components/Chart/ChartRenderer.tsx b/superset-frontend/src/components/Chart/ChartRenderer.tsx index 27a69243645..a2c66662ea7 100644 --- a/superset-frontend/src/components/Chart/ChartRenderer.tsx +++ b/superset-frontend/src/components/Chart/ChartRenderer.tsx @@ -235,7 +235,11 @@ class ChartRenderer extends Component { onFilterMenuClose: this.props.onFilterMenuClose, onLegendStateChanged: this.handleLegendStateChanged, setDataMask: (dataMask: DataMask) => { - this.props.actions?.updateDataMask?.(this.props.chartId, dataMask); + if (this.props.actions?.updateDataMask) { + this.props.actions.updateDataMask(this.props.chartId, dataMask); + } else { + this.props.setDataMask?.(dataMask); + } }, onLegendScroll: this.handleLegendScroll, onChartStateChange: this.props.onChartStateChange,