From 5da3ffcb661715743c6ba995a9ba8ac6fef339fb Mon Sep 17 00:00:00 2001 From: Joseph Schorr Date: Wed, 16 Apr 2014 22:43:13 -0400 Subject: [PATCH] Add a null check to make sure we don't try to update the tree before it has rendered --- static/js/graphing.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/static/js/graphing.js b/static/js/graphing.js index 8e710e9aa..02a4d3fd3 100644 --- a/static/js/graphing.js +++ b/static/js/graphing.js @@ -909,6 +909,8 @@ FileTreeBase.prototype.calculateDimensions_ = function(container) { * Updates the dimensions of the tree. */ FileTreeBase.prototype.updateDimensions_ = function() { + if (!this.rootSvg_) { return; } + var container = this.container_; var dimensions = this.calculateDimensions_(container);