aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/node.rs
diff options
context:
space:
mode:
Diffstat (limited to 'components/script/dom/node.rs')
-rw-r--r--components/script/dom/node.rs4
1 files changed, 1 insertions, 3 deletions
diff --git a/components/script/dom/node.rs b/components/script/dom/node.rs
index 17764636b0c..c406757d450 100644
--- a/components/script/dom/node.rs
+++ b/components/script/dom/node.rs
@@ -2286,9 +2286,7 @@ impl<'a> style::TNode<'a, JSRef<'a, Element>> for JSRef<'a, Node> {
}
fn is_html_element_in_html_document(self) -> bool {
- let elem: Option<JSRef<'a, Element>> = ElementCast::to_ref(self);
- assert!(elem.is_some());
- elem.unwrap().html_element_in_html_document()
+ self.as_element().html_element_in_html_document()
}
fn has_changed(self) -> bool { self.get_has_changed() }