fix for issue 380 from adilh
authorDan Vanderkam <danvk@google.com>
Mon, 17 Sep 2012 20:45:20 +0000 (16:45 -0400)
committerDan Vanderkam <danvk@google.com>
Mon, 17 Sep 2012 20:45:20 +0000 (16:45 -0400)
dygraph.js

index 0fc48ce..621ea32 100644 (file)
@@ -1536,7 +1536,8 @@ Dygraph.prototype.doUnzoom_ = function() {
       newValueRanges = [];
       for (i = 0; i < this.axes_.length; i++) {
         var axis = this.axes_[i];
-        newValueRanges.push(axis.valueRange !== null ?
+        newValueRanges.push((axis.valueRange !== null &&
+                             axis.valueRange !== undefined) ?
                             axis.valueRange : axis.extremeRange);
       }
     }