Skip to content

Commit

Permalink
Use more concise loop iteration
Browse files Browse the repository at this point in the history
  • Loading branch information
WhyNotHugo authored and pr2502 committed Oct 25, 2023
1 parent 1c6857b commit 496402f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/instance.rs
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ async fn gc_task(
loop {
interval.tick().await;

for (key, instance) in instance_map.lock().await.0.iter() {
for (key, instance) in &instance_map.lock().await.0 {
let mut message_readers = instance.clients.lock().await;

// Remove closed senders
Expand Down

0 comments on commit 496402f

Please sign in to comment.