mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Fix HTMLCollection::NamedItem
This commit is contained in:
parent
7f36247d03
commit
7696a6bd20
4 changed files with 2 additions and 13 deletions
|
@ -337,8 +337,8 @@ impl HTMLCollectionMethods for HTMLCollection {
|
|||
|
||||
// Step 2.
|
||||
self.elements_iter().find(|elem| {
|
||||
elem.get_string_attribute(&atom!("name")) == key ||
|
||||
elem.get_string_attribute(&atom!("id")) == key
|
||||
elem.get_string_attribute(&atom!("id")) == key ||
|
||||
(elem.namespace() == &ns!(html) && elem.get_string_attribute(&atom!("name")) == key)
|
||||
})
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue