Skip to content

Commit 3102fab

Browse files
benmccannetimberg
authored andcommitted
Fix undefined variable (chartjs#6698)
1 parent efa5523 commit 3102fab

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/core/core.scale.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -356,7 +356,7 @@ var Scale = Element.extend({
356356
*/
357357
_getLabels: function() {
358358
var data = this.chart.data;
359-
return this.options.labels || (this.isHorizontal() ? data.xLabels : data.yLabels) || data.labels;
359+
return this.options.labels || (this.isHorizontal() ? data.xLabels : data.yLabels) || data.labels || [];
360360
},
361361

362362
// These methods are ordered by lifecyle. Utilities then follow.

0 commit comments

Comments
 (0)