diff --git a/lib/timeline/component/LineGraph.js b/lib/timeline/component/LineGraph.js index 892c8171..d10bb17d 100644 --- a/lib/timeline/component/LineGraph.js +++ b/lib/timeline/component/LineGraph.js @@ -820,7 +820,8 @@ LineGraph.prototype._updateYAxis = function (groupIds, groupRanges) { if (groupIds.length > 0) { // this is here to make sure that if there are no items in the axis but there are groups, that there is no infinite draw/redraw loop. for (var i = 0; i < groupIds.length; i++) { - if (this.groups[groupIds[i]].options.yAxisOrientation == 'left') { + var group = this.groups[groupIds[i]]; + if (group && group.options.yAxisOrientation == 'left') { yAxisLeftUsed = true; minLeft = 0; maxLeft = 0;