mirror of
https://github.com/servo/servo.git
synced 2025-07-23 07:13:52 +01:00
Use a Temporary iterator in Node::collect_text_contents()
This commit is contained in:
parent
e57630711f
commit
cdb3efec87
2 changed files with 6 additions and 5 deletions
|
@ -524,8 +524,7 @@ impl<'a> HTMLScriptElementMethods for JSRef<'a, HTMLScriptElement> {
|
|||
|
||||
// http://www.whatwg.org/html/#dom-script-text
|
||||
fn Text(self) -> DOMString {
|
||||
let node: JSRef<Node> = NodeCast::from_ref(self);
|
||||
Node::collect_text_contents(node.children().map(|c| c.root()).map(|c| c.get_unsound_ref_forever()))
|
||||
Node::collect_text_contents(NodeCast::from_ref(self).children())
|
||||
}
|
||||
|
||||
// http://www.whatwg.org/html/#dom-script-text
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue