From 1eaa467afcc3b9f76bd93f6af640727c183086b6 Mon Sep 17 00:00:00 2001 From: janekptacijarabaci Date: Sun, 13 May 2018 08:28:44 +0200 Subject: about:sessionrestore - fix an error "treeView.treeBox is null" in aboutSessionRestore.js --- browser/components/sessionstore/content/aboutSessionRestore.js | 3 +++ 1 file changed, 3 insertions(+) (limited to 'browser/components/sessionstore') diff --git a/browser/components/sessionstore/content/aboutSessionRestore.js b/browser/components/sessionstore/content/aboutSessionRestore.js index 8a9410aa8..165f48041 100644 --- a/browser/components/sessionstore/content/aboutSessionRestore.js +++ b/browser/components/sessionstore/content/aboutSessionRestore.js @@ -188,6 +188,9 @@ function onListClick(aEvent) { if (aEvent.button == 2) return; + if (!treeView.treeBox) { + return; + } var cell = treeView.treeBox.getCellAt(aEvent.clientX, aEvent.clientY); if (cell.col) { // Restore this specific tab in the same window for middle/double/accel clicking -- cgit v1.2.3 From faf4b17b3cc192a989a6c0b36a0973c04ddab3c0 Mon Sep 17 00:00:00 2001 From: janekptacijarabaci Date: Sun, 13 May 2018 08:29:42 +0200 Subject: about:welcomeback - fix an error "invalid 'in' operand gTreeData[idx]" in aboutSessionRestore.js --- browser/components/sessionstore/content/aboutSessionRestore.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'browser/components/sessionstore') diff --git a/browser/components/sessionstore/content/aboutSessionRestore.js b/browser/components/sessionstore/content/aboutSessionRestore.js index 165f48041..8f265235d 100644 --- a/browser/components/sessionstore/content/aboutSessionRestore.js +++ b/browser/components/sessionstore/content/aboutSessionRestore.js @@ -289,7 +289,9 @@ var treeView = { get rowCount() { return gTreeData.length; }, setTree: function(treeBox) { this.treeBox = treeBox; }, getCellText: function(idx, column) { return gTreeData[idx].label; }, - isContainer: function(idx) { return "open" in gTreeData[idx]; }, + isContainer: function(idx) { + return gTreeData[idx] ? "open" in gTreeData[idx] : false; + }, getCellValue: function(idx, column){ return gTreeData[idx].checked; }, isContainerOpen: function(idx) { return gTreeData[idx].open; }, isContainerEmpty: function(idx) { return false; }, -- cgit v1.2.3