Skip to content

Commit

Permalink
Using indexOf instead of includes for isXAxisString (#3733)
Browse files Browse the repository at this point in the history
  • Loading branch information
michellethomas authored and mistercrunch committed Oct 27, 2017
1 parent cbd0107 commit 200b66d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion superset/assets/visualizations/nvd3_vis.js
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,7 @@ function nvd3Vis(slice, payload) {
chart.x2Axis.tickFormat(xAxisFormatter);
height += 30;
}
const isXAxisString = ['dist_bar', 'box_plot'].includes(vizType) >= 0;
const isXAxisString = ['dist_bar', 'box_plot'].indexOf(vizType) >= 0;
if (!isXAxisString && chart.xAxis && chart.xAxis.tickFormat) {
chart.xAxis.tickFormat(xAxisFormatter);
}
Expand Down

0 comments on commit 200b66d

Please sign in to comment.