diff --git a/src/charts/Line.js b/src/charts/Line.js index 9e1172477..43b7dce5f 100644 --- a/src/charts/Line.js +++ b/src/charts/Line.js @@ -387,7 +387,7 @@ class Line { if (forecast.count > 0 && type !== 'rangeArea') { const forecastCutoff = w.globals.seriesXvalues[realIndex][ - w.globals.seriesXvalues[realIndex].length - forecast.count - 1 + w.globals.seriesXvalues[realIndex].length - forecast.count - 1 ] const elForecastMask = graphics.drawRect( forecastCutoff, @@ -642,7 +642,9 @@ class Line { } // push current X - xArrj.push(x) + if (typeof w.globals.seriesX[realIndex][j + 1] !== 'undefined') { + xArrj.push(x) + } // push current Y that will be used as next series's bottom position if (