aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/document.rs
diff options
context:
space:
mode:
authorOluwatobi Sofela <60105594+oluwatobiss@users.noreply.github.com>2024-03-21 18:04:18 +0100
committerGitHub <noreply@github.com>2024-03-21 17:04:18 +0000
commit694e86ecffb882f6d5934eb620257e9fceddbca8 (patch)
tree9046ce71d1b16bd64490078fdfb6eac87b064ef5 /components/script/dom/document.rs
parentb22281d94f230c455142b73576904fdec2d1140a (diff)
downloadservo-694e86ecffb882f6d5934eb620257e9fceddbca8.tar.gz
servo-694e86ecffb882f6d5934eb620257e9fceddbca8.zip
clippy: Fix dereferencing a tuple pattern warnings (#31811)
Diffstat (limited to 'components/script/dom/document.rs')
-rw-r--r--components/script/dom/document.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/components/script/dom/document.rs b/components/script/dom/document.rs
index 640feba005c..a41a1a6222b 100644
--- a/components/script/dom/document.rs
+++ b/components/script/dom/document.rs
@@ -1762,8 +1762,8 @@ impl Document {
let body = self.GetBody();
let target = match (&focused, &body) {
- (&Some(ref focused), _) => focused.upcast(),
- (&None, &Some(ref body)) => body.upcast(),
+ (Some(focused), _) => focused.upcast(),
+ (&None, Some(body)) => body.upcast(),
(&None, &None) => self.window.upcast(),
};
@@ -4640,7 +4640,7 @@ impl DocumentMethods for Document {
match (self.GetDocumentElement(), &old_body) {
// Step 3.
- (Some(ref root), &Some(ref child)) => {
+ (Some(ref root), Some(child)) => {
let root = root.upcast::<Node>();
root.ReplaceChild(new_body.upcast(), child.upcast())
.unwrap();