aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/testbindingpairiterable.rs
diff options
context:
space:
mode:
authorAarya Khandelwal <119049564+Aaryakhandelwal@users.noreply.github.com>2024-03-22 11:11:17 +0530
committerGitHub <noreply@github.com>2024-03-22 05:41:17 +0000
commit9b26dca141159ddc75266de9ef5a54f537450921 (patch)
treec6ad0681bfbf5a15f4916ec45827a2a52be19ade /components/script/dom/testbindingpairiterable.rs
parent95e69fe4ffce23708608855720961741344bee07 (diff)
downloadservo-9b26dca141159ddc75266de9ef5a54f537450921.tar.gz
servo-9b26dca141159ddc75266de9ef5a54f537450921.zip
Fixed the .clone() warnings. (#31819)
Diffstat (limited to 'components/script/dom/testbindingpairiterable.rs')
-rw-r--r--components/script/dom/testbindingpairiterable.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/components/script/dom/testbindingpairiterable.rs b/components/script/dom/testbindingpairiterable.rs
index 15ff3c2c752..6496f3c9a07 100644
--- a/components/script/dom/testbindingpairiterable.rs
+++ b/components/script/dom/testbindingpairiterable.rs
@@ -29,13 +29,13 @@ impl Iterable for TestBindingPairIterable {
self.map.borrow().len() as u32
}
fn get_value_at_index(&self, index: u32) -> u32 {
- self.map
+ *self
+ .map
.borrow()
.iter()
.nth(index as usize)
.map(|a| &a.1)
.unwrap()
- .clone()
}
fn get_key_at_index(&self, index: u32) -> DOMString {
self.map