From 2acd9bd45d23838bbee61561aaa05c1443d5ebb0 Mon Sep 17 00:00:00 2001 From: toasted-nutbread Date: Wed, 10 Mar 2021 20:26:53 -0500 Subject: Fix previousStyles being recreated for every transparent element (#1512) --- ext/js/dom/document-util.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ext') diff --git a/ext/js/dom/document-util.js b/ext/js/dom/document-util.js index 393ef294..8284ffa5 100644 --- a/ext/js/dom/document-util.js +++ b/ext/js/dom/document-util.js @@ -578,7 +578,7 @@ class DocumentUtil { startContinerPre = startContainer; } - previousStyles = new Map(); + if (previousStyles === null) { previousStyles = new Map(); } i = this._disableTransparentElement(elements, i, previousStyles); if (i < 0) { return null; -- cgit v1.2.3