1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-07-05 11:37:01 +02:00
Use document.append() only when there are no elements in
the DOM, as a document instance can't have more than one
direct child.
This commit is contained in:
Raymond Hill 2023-05-23 21:49:42 -04:00
parent d5804dce7f
commit 9134c11cf8
No known key found for this signature in database
GPG Key ID: 25E1490B761470C2

View File

@ -315,7 +315,7 @@ vAPI.scriptletsInjector = ((doc, details) => {
script = doc.createElement('script');
script.async = false;
script.src = url;
doc.append(script);
(doc.head || doc.documentElement || doc).append(script);
self.uBO_scriptletsInjected = details.filters;
} catch (ex) {
}