aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/node.rs
diff options
context:
space:
mode:
authorAnthony Ramine <n.oxyde@gmail.com>2016-11-30 13:57:22 +0100
committerAnthony Ramine <n.oxyde@gmail.com>2016-12-01 11:55:13 +0100
commitfb206e2b1020bd40122a48affc04f6b9f6352d39 (patch)
tree405974ad984efb765b00e5f60643f5f21d179855 /components/script/dom/node.rs
parenta377caa7e9d68a97156b968964bb7bc18444d13d (diff)
downloadservo-fb206e2b1020bd40122a48affc04f6b9f6352d39.tar.gz
servo-fb206e2b1020bd40122a48affc04f6b9f6352d39.zip
Make Attr::prefix return an Option<&Prefix>
Diffstat (limited to 'components/script/dom/node.rs')
-rw-r--r--components/script/dom/node.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/components/script/dom/node.rs b/components/script/dom/node.rs
index f47d2583ae5..2d2440db842 100644
--- a/components/script/dom/node.rs
+++ b/components/script/dom/node.rs
@@ -1768,7 +1768,7 @@ impl Node {
attr.value().clone(),
attr.name().clone(),
attr.namespace().clone(),
- attr.prefix().clone());
+ attr.prefix().cloned());
}
},
_ => ()
@@ -1815,10 +1815,10 @@ impl Node {
defined_prefix: &Option<LocalName>) -> bool {
*attr.namespace() == ns!(xmlns) &&
match (attr.prefix(), defined_prefix) {
- (&Some(ref attr_prefix), &Some(ref defined_prefix)) =>
+ (Some(attr_prefix), &Some(ref defined_prefix)) =>
attr_prefix == &namespace_prefix!("xmlns") &&
attr.local_name() == defined_prefix,
- (&None, &None) => *attr.local_name() == local_name!("xmlns"),
+ (None, &None) => *attr.local_name() == local_name!("xmlns"),
_ => false
}
}