mirror of
https://github.com/servo/servo.git
synced 2025-07-22 23:03:42 +01:00
Update to string-cache 0.3
This commit is contained in:
parent
9fcc9d9d3f
commit
53b638c0e2
170 changed files with 1309 additions and 1050 deletions
|
@ -913,10 +913,10 @@ impl RangeMethods for Range {
|
|||
// Step 2.
|
||||
let should_create_body = element.as_ref().map_or(true, |elem| {
|
||||
let elem = elem.downcast::<Element>().unwrap();
|
||||
elem.local_name() == &atom!("html") && elem.html_element_in_html_document()
|
||||
elem.local_name() == &local_name!("html") && elem.html_element_in_html_document()
|
||||
});
|
||||
let element: Root<Node> = if should_create_body {
|
||||
Root::upcast(HTMLBodyElement::new(atom!("body"), None, &self.StartContainer().owner_doc()))
|
||||
Root::upcast(HTMLBodyElement::new(local_name!("body"), None, &self.StartContainer().owner_doc()))
|
||||
} else {
|
||||
Root::upcast(element.unwrap())
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue