Merge pull request #5792 from tvatavuk/patch-4

This commit is contained in:
Shaun Walker
2025-11-10 11:17:13 -05:00
committed by GitHub

View File

@ -124,7 +124,7 @@ Oqtane.Interop = {
}
},
includeScript: function (id, src, integrity, crossorigin, type, content, location, dataAttributes) {
var script;
var script = null;
if (src !== "") {
script = document.querySelector("script[src=\"" + CSS.escape(src) + "\"]");
}
@ -140,7 +140,7 @@ Oqtane.Interop = {
}
}
}
if (script !== null) {
if (script instanceof HTMLScriptElement) {
script.remove();
script = null;
}