1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-11-23 10:07:19 +00:00

Fix crash when closing plugin library

Fixes #6855
This commit is contained in:
jeremy@jermolene.com 2022-07-31 15:35:14 +01:00
parent 091a6a9dc1
commit 667da96c97

View File

@ -62,12 +62,14 @@ function loadIFrame(url,callback) {
Unload library iframe for given url
*/
function unloadIFrame(url){
$tw.utils.each(document.getElementsByTagName('iframe'), function(iframe) {
var iframes = document.getElementsByTagName('iframe');
for(var t=iframes.length-1; t--; t>=0) {
var iframe = iframes[t];
if(iframe.getAttribute("library") === "true" &&
iframe.getAttribute("src") === url) {
iframe.parentNode.removeChild(iframe);
}
});
}
}
function saveIFrameInfoTiddler(iframeInfo) {