When checking if you should renderTriggered make sure key exists in controls (#3912)

This commit is contained in:
michellethomas
2017-11-21 10:22:55 -08:00
committed by Grace Guo
parent feb15a30a2
commit 12fb7c1a62

View File

@@ -53,6 +53,7 @@ class ExploreViewContainer extends React.Component {
}
// if any control value changed and it's an instant control
if (Object.keys(np.controls).some(key => (np.controls[key].renderTrigger &&
typeof this.props.controls[key] !== 'undefined' &&
!areObjectsEqual(np.controls[key].value, this.props.controls[key].value)))) {
this.props.actions.renderTriggered(new Date().getTime(), this.props.chart.chartKey);
}