mirror of
https://github.com/lightpanda-io/browser.git
synced 2026-03-22 20:54:43 +00:00
use node.firstChild() directly per review feedback
node is already available in scope — no need to traverse back through script.asConstElement().asConstNode().
This commit is contained in:
@@ -2911,7 +2911,7 @@ fn nodeIsReady(self: *Page, comptime from_parser: bool, node: *Node) !void {
|
|||||||
// Script was added via JavaScript without a src attribute.
|
// Script was added via JavaScript without a src attribute.
|
||||||
// Only skip if it has no inline content either — scripts with
|
// Only skip if it has no inline content either — scripts with
|
||||||
// textContent/text should still execute per spec.
|
// textContent/text should still execute per spec.
|
||||||
if (script.asConstElement().asConstNode().firstChild() == null) {
|
if (node.firstChild() == null) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user