From: Robert Konigsberg Date: Wed, 21 Dec 2011 18:45:22 +0000 (-0500) Subject: Add var declaration to prevent breaking stacked graphs. X-Git-Tag: v1.0.0~399 X-Git-Url: https://adrianiainlam.tk/git/?a=commitdiff_plain;h=47927039a011d5cd57704bb08f64f02eca166a82;p=dygraphs.git Add var declaration to prevent breaking stacked graphs. --- diff --git a/dygraph-canvas.js b/dygraph-canvas.js index 77d8cc4..b184717 100644 --- a/dygraph-canvas.js +++ b/dygraph-canvas.js @@ -743,7 +743,7 @@ DygraphCanvasRenderer.prototype._renderLineChart = function() { } var newYs; if (stackedGraph) { - lastY = baseline[point.canvasx]; + var lastY = baseline[point.canvasx]; if (lastY === undefined) lastY = axisY; baseline[point.canvasx] = point.canvasy; newYs = [ point.canvasy, lastY ];