Fix #10004 iframe DOM leak in unloadIFrame loop (#10018)

* Fix unloadIFrame loop condition for proper iframe unloading

* add changenote for #10018

* add missing field to changenote
This commit is contained in:
Théophile Desmedt authored and GitHub committed 2026-09-08 12:11:06 +04:00
1 parent 30a51be168
commit d62b75cceb
2 files changed
+13 -1

No files matched your search

+1 -1
View File
@@ -60,7 +60,7 @@ Unload library iframe for given url
*/
function unloadIFrame(url){
var iframes = document.getElementsByTagName("iframe");
for(var t=iframes.length-1; t--; t>=0) {
for(var t = iframes.length - 1; t >= 0; t--) {
var iframe = iframes[t];
if(iframe.getAttribute("library") === "true" &&
iframe.getAttribute("src") === url) {
@@ -0,0 +1,12 @@
change-category: internal
change-type: bugfix
created: 20260907175854854
description: Fixed a DOM leak when closing the plugin library
github-links: https://github.com/TiddlyWiki/TiddlyWiki5/pull/10018
release: 5.5.0
tags: $:/tags/ChangeNote
title: $:/changenotes/5.5.0/#10018
type: text/vnd.tiddlywiki
github-contributors: DesignThinkerer
Fixed a syntax error in the `unloadIFrame` loop that permanently left a hidden `<iframe library="true">` attached to the DOM every time the plugin library modal was closed.