Some points may be null, not just undefined, so compare points via != with
authorAdam Vartanian <flooey@gmail.com>
Mon, 3 May 2010 21:24:51 +0000 (17:24 -0400)
committerAdam Vartanian <flooey@gmail.com>
Mon, 3 May 2010 21:24:51 +0000 (17:24 -0400)
null (which will return false for both null and undefined).

dygraph.js

index 077a329..eff107c 100644 (file)
@@ -1529,7 +1529,7 @@ Dygraph.prototype.drawGraph_ = function(data) {
 
     var series = [];
     for (var j = 0; j < data.length; j++) {
-      if (data[j][i] !== undefined || !connectSeparatedPoints) {
+      if (data[j][i] != null || !connectSeparatedPoints) {
         var date = data[j][0];
         series.push([date, data[j][i]]);
       }