mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-27 18:17:22 +02:00
LibWeb: Ensure document.getElementById("") returns null
Previously, if a document had an element whose id was the empty string,
then `document.getElementById("")` and `element.getElementById("")`
would return that element.
This commit is contained in:
committed by
Andreas Kling
parent
18499c4eac
commit
f666d967d6
Notes:
github-actions[bot]
2024-07-23 06:59:28 +00:00
Author: https://github.com/tcl3 Commit: https://github.com/LadybirdBrowser/ladybird/commit/f666d967d6b Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/773
@@ -0,0 +1,8 @@
|
||||
<!DOCTYPE html>
|
||||
<script src="../include.js"></script>
|
||||
<div id=""></div>
|
||||
<script>
|
||||
test(() => {
|
||||
println(`document.getElementById(""): ${document.getElementById("")}`);
|
||||
});
|
||||
</script>
|
||||
Reference in New Issue
Block a user