diff --git a/content/treestyletab/treestyletab.js b/content/treestyletab/treestyletab.js index 164e7f57..85ab3b11 100644 --- a/content/treestyletab/treestyletab.js +++ b/content/treestyletab/treestyletab.js @@ -146,11 +146,12 @@ var TreeStyleTabService = { shouldOpenSearchResultAsChild : function TSTService_shouldOpenSearchResultAsChild(aTerm) { var mode = this.getTreePref('autoAttachSearchResultAsChildren'); - if (mode == this.kSEARCH_RESULT_ATTACH_ALWAYS) + if (mode == this.kSEARCH_RESULT_ATTACH_ALWAYS) { return true; - - if (!aTerm || mode == this.kSEARCH_RESULT_DO_NOT_ATTACH) + } + else if (!aTerm || mode == this.kSEARCH_RESULT_DO_NOT_ATTACH) { return false; + } var w = document.commandDispatcher.focusedWindow; if (!w || w.top != this.browser.contentWindow)