From 8ae21be0e2cf4c22f8f7b8e59fdc201d33bd1862 Mon Sep 17 00:00:00 2001 From: baku Date: Fri, 3 Feb 2017 18:55:52 +0100 Subject: [PATCH] Correct remove method for tabs #145 --- webextension/js/popup.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/webextension/js/popup.js b/webextension/js/popup.js index 9e26b65..a11d54d 100644 --- a/webextension/js/popup.js +++ b/webextension/js/popup.js @@ -322,8 +322,9 @@ Logic.registerPanel(P_CONTAINER_INFO, { hideShowLabel.innerText = identity.hasHiddenTabs ? "Show these container tabs" : "Hide these container tabs"; // Let's remove all the previous tabs. - for (let trTab of document.getElementsByClassName("container-info-tab-row")) { // eslint-disable-line prefer-const - trTab.remove(); + const table = document.getElementById("container-info-table"); + while (table.firstChild) { + table.firstChild.remove(); } // Let's retrieve the list of tabs.