Skip to content
This repository has been archived by the owner on Dec 10, 2021. It is now read-only.

Commit

Permalink
fix: nvd3 charts break on stateChange dispatch (#159)
Browse files Browse the repository at this point in the history
  • Loading branch information
Erik Ritter committed Jul 29, 2019
1 parent da027f6 commit 525779d
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -654,7 +654,9 @@ function nvd3Vis(element, props) {
applyYAxisBounds();

// Also reapply on each state change to account for enabled/disabled series
chart.dispatch.on('stateChange.applyYAxisBounds', applyYAxisBounds);
if (chart.dispatch && chart.dispatch.stateChange) {
chart.dispatch.on('stateChange.applyYAxisBounds', applyYAxisBounds);
}

// align yAxis1 and yAxis2 ticks
if (isVizTypes(['dual_line', 'line_multi'])) {
Expand Down

0 comments on commit 525779d

Please sign in to comment.