diff --git a/javascript/LeftAndMain.Tree.js b/javascript/LeftAndMain.Tree.js index a7bd9ca6..215fe418 100755 --- a/javascript/LeftAndMain.Tree.js +++ b/javascript/LeftAndMain.Tree.js @@ -75,7 +75,7 @@ TreeAPI.prototype = { function(data, status){ self.innerHTML = data; self.castAsTreeNode(self.firstChild); - if (options.onSuccess) options.onSuccess(data); + if (options && options.onSuccess) options.onSuccess(data); }, 'html' );