mirror of
https://github.com/servo/servo.git
synced 2025-07-22 23:03:42 +01:00
Removed JS::root Fixes #8251
This commit is contained in:
parent
521a87180a
commit
d8ef3809a6
25 changed files with 98 additions and 126 deletions
|
@ -45,7 +45,7 @@ impl Sink {
|
|||
#[allow(unrooted_must_root)] // method is only run at parse time
|
||||
pub fn get_or_create(&self, child: NodeOrText<JS<Node>>) -> Root<Node> {
|
||||
match child {
|
||||
NodeOrText::AppendNode(n) => n.root(),
|
||||
NodeOrText::AppendNode(n) => Root::from_ref(&*n),
|
||||
NodeOrText::AppendText(t) => {
|
||||
let text = Text::new(t.into(), &self.document);
|
||||
Root::upcast(text)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue