X-Git-Url: https://adrianiainlam.tk/git/?a=blobdiff_plain;f=dygraph-utils.js;h=63411a599627809693bf15837ee47d466558f39c;hb=e11c15fd04a8848a1fe695bfb1892571ff06deb5;hp=f5440c7b3d7236b2d822d09137c103452deb00c1;hpb=117b8bee20ce2bf7d36668af054285244d438b5c;p=dygraphs.git diff --git a/dygraph-utils.js b/dygraph-utils.js index f5440c7..63411a5 100644 --- a/dygraph-utils.js +++ b/dygraph-utils.js @@ -598,7 +598,7 @@ Dygraph.updateDeep = function (self, o) { // DOM objects are shallowly-copied. self[k] = o[k]; } else if (typeof(o[k]) == 'object') { - if (typeof(self[k]) != 'object') { + if (typeof(self[k]) != 'object' || self[k] === null) { self[k] = {}; } Dygraph.updateDeep(self[k], o[k]);