diff options
author | Azhar Ismagulova <31756707+azharcodeit@users.noreply.github.com> | 2024-03-29 08:58:22 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-03-29 08:58:22 +0000 |
commit | c4739675d8bf83a83d8e26d5d7527180f003e7d5 (patch) | |
tree | ce5d2642396eb98dc495078ffac97477916bf1e7 /components/script/dom/globalscope.rs | |
parent | 2d5a1cd02ee0c3196875dc52ca55a150a63cc29f (diff) | |
download | servo-c4739675d8bf83a83d8e26d5d7527180f003e7d5.tar.gz servo-c4739675d8bf83a83d8e26d5d7527180f003e7d5.zip |
clippy: Fix needless_borrow warnings in components/script (#31928)
Diffstat (limited to 'components/script/dom/globalscope.rs')
-rw-r--r-- | components/script/dom/globalscope.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/components/script/dom/globalscope.rs b/components/script/dom/globalscope.rs index 6668053fe67..8f91aea597e 100644 --- a/components/script/dom/globalscope.rs +++ b/components/script/dom/globalscope.rs @@ -1209,7 +1209,7 @@ impl GlobalScope { if let Some(channels) = channels.get(&channel_name) { channels .iter() - .filter(|ref channel| { + .filter(|channel| { // Step 8. // Filter out the sender. if let Some(id) = channel_id { @@ -1355,7 +1355,7 @@ impl GlobalScope { { let to_be_removed: Vec<MessagePortId> = message_ports .iter() - .filter_map(|(id, ref managed_port)| { + .filter_map(|(id, managed_port)| { if managed_port.closed { // Let the constellation know to drop this port and the one it is entangled with, // and to forward this message to the script-process where the entangled is found. @@ -1388,7 +1388,7 @@ impl GlobalScope { &mut *self.broadcast_channel_state.borrow_mut() { channels.retain(|name, ref mut channels| { - channels.retain(|ref chan| !chan.closed()); + channels.retain(|chan| !chan.closed()); if channels.is_empty() { let _ = self.script_to_constellation_chan().send( ScriptMsg::RemoveBroadcastChannelNameInRouter( |