From df8efe59f4e4131b48682b9fcb74be46335eb0da Mon Sep 17 00:00:00 2001 From: NTD Date: Thu, 5 Apr 2018 07:26:12 -0400 Subject: [PATCH] [PALEMOON] Fix for loops in treeView.js (SyntaxError: missing ] after element list) --- application/palemoon/components/places/content/treeView.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/application/palemoon/components/places/content/treeView.js b/application/palemoon/components/places/content/treeView.js index c1879aacf1..aba7314700 100644 --- a/application/palemoon/components/places/content/treeView.js +++ b/application/palemoon/components/places/content/treeView.js @@ -144,7 +144,12 @@ PlacesTreeView.prototype = { // A node is removed form the view either if it has no parent or if its // root-ancestor is not the root node (in which case that's the node // for which nodeRemoved was called). - let ancestors = [x for (x of PlacesUtils.nodeAncestors(aNode))]; + // Tycho: let ancestors = [x for (x of PlacesUtils.nodeAncestors(aNode))]; + let ancestors = []; + for (let x of PlacesUtils.nodeAncestors(aNode)) { + ancestors.push(x); + } + if (ancestors.length == 0 || ancestors[ancestors.length - 1] != this._rootNode) { throw new Error("Removed node passed to _getRowForNode");