From fb2ddc4504313688c2b69aa326e1db30c0fefc92 Mon Sep 17 00:00:00 2001 From: Ingo Schommer Date: Tue, 27 Jan 2009 01:16:18 +0000 Subject: [PATCH] MINOR Defensive handling of events in TreeSelectorField->hideTree git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@70769 467b73ca-7a2a-4603-9d3b-597d59a354a9 --- javascript/TreeSelectorField.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/javascript/TreeSelectorField.js b/javascript/TreeSelectorField.js index 0c92f9467..13d5c17a0 100755 --- a/javascript/TreeSelectorField.js +++ b/javascript/TreeSelectorField.js @@ -134,7 +134,7 @@ TreeDropdownField.prototype = { this.treeShown = false; if(this.itemTree) { this.itemTree.style.display = 'none'; - Event.stopObserving(document, 'click', this.bound_testForBlur); + if(this.bound_testForBlur) Event.stopObserving(document, 'click', this.bound_testForBlur); // this.editLink.style.display = this.humanItems.style.display = 'block'; this.unstretchIframeIfNeeded(); }