From 8daeb74b53debed417fc7faadc5b34e20d269607 Mon Sep 17 00:00:00 2001 From: Titouan Rigoudy Date: Sat, 24 Nov 2018 20:19:28 +0000 Subject: [PATCH] Run cargo fmt. --- src/client.rs | 9 +++------ src/control/ws.rs | 9 +++------ 2 files changed, 6 insertions(+), 12 deletions(-) diff --git a/src/client.rs b/src/client.rs index 33d7795..d489f5f 100644 --- a/src/client.rs +++ b/src/client.rs @@ -354,8 +354,7 @@ impl Client { user_name: peer.user_name.clone(), connection_type: peer.connection_type.clone(), }), - )) - .unwrap(); + )).unwrap(); } PeerState::OpeningFirewalled => { @@ -371,8 +370,7 @@ impl Client { token: peer.token, user_name: peer.user_name, }), - )) - .unwrap(); + )).unwrap(); } } } @@ -519,8 +517,7 @@ impl Client { peer_id, response.ip, response.port, - )) - .unwrap(); + )).unwrap(); } Err(peer) => { diff --git a/src/control/ws.rs b/src/control/ws.rs index 3a48e47..83d5c20 100644 --- a/src/control/ws.rs +++ b/src/control/ws.rs @@ -159,8 +159,7 @@ pub fn listen(client_tx: mpsc::Sender) { .with_settings(ws::Settings { max_connections: 1, ..ws::Settings::default() - }) - .build(|socket_tx| Handler { + }).build(|socket_tx| Handler { client_tx: client_tx.clone(), socket_tx: socket_tx, }); @@ -173,8 +172,7 @@ pub fn listen(client_tx: mpsc::Sender) { .send(Notification::Error(format!( "Unable to build websocket: {}", e - ))) - .unwrap(); + ))).unwrap(); return; } }; @@ -189,8 +187,7 @@ pub fn listen(client_tx: mpsc::Sender) { .send(Notification::Error(format!( "Unable to listen on websocket: {}", e - ))) - .unwrap(); + ))).unwrap(); } } }