aboutsummaryrefslogtreecommitdiff
path: root/crates/whirl_server/src/interaction/shared.rs
diff options
context:
space:
mode:
authorFuwn <[email protected]>2021-05-28 00:06:40 -0700
committerFuwn <[email protected]>2021-05-28 00:06:40 -0700
commit179ce3277ece536cae41b834469f4065e3600d82 (patch)
treea96d55a34531c9761f6309c35f8d9cfab9879db6 /crates/whirl_server/src/interaction/shared.rs
parentMerge branch 'develop' of https://github.com/Whirlsplash/whirl into develop (diff)
downloadwhirl-179ce3277ece536cae41b834469f4065e3600d82.tar.xz
whirl-179ce3277ece536cae41b834469f4065e3600d82.zip
fix(global): a lot of clippy warnings
This change makes clippy **a lot** more strict.
Diffstat (limited to 'crates/whirl_server/src/interaction/shared.rs')
-rw-r--r--crates/whirl_server/src/interaction/shared.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/whirl_server/src/interaction/shared.rs b/crates/whirl_server/src/interaction/shared.rs
index c2ee671..7ad2510 100644
--- a/crates/whirl_server/src/interaction/shared.rs
+++ b/crates/whirl_server/src/interaction/shared.rs
@@ -12,13 +12,13 @@ pub struct Shared {
}
impl Shared {
pub fn new() -> Self {
- Shared {
+ Self {
peers: HashMap::new(),
}
}
pub async fn broadcast(&mut self, message: &[u8]) {
- for peer in self.peers.iter_mut() {
+ for peer in &mut self.peers {
peer.1.send(BytesMut::from(message)).unwrap();
}
}