diff options
| author | Linus Färnstrand <linus@mullvad.net> | 2019-06-12 14:45:39 +0200 |
|---|---|---|
| committer | Linus Färnstrand <linus@mullvad.net> | 2019-06-12 15:17:07 +0200 |
| commit | abeb26f947f6fcf1c35a407c6ca90de1f91a1492 (patch) | |
| tree | 983b7c403cecc1941bd2a19e081a75bce6b96221 | |
| parent | 57da9f8609a955dee1da95e7a4f0bc30976134f8 (diff) | |
| download | mullvadvpn-abeb26f947f6fcf1c35a407c6ca90de1f91a1492.tar.xz mullvadvpn-abeb26f947f6fcf1c35a407c6ca90de1f91a1492.zip | |
Remove superfluous return keyword
| -rw-r--r-- | mullvad-daemon/src/relays.rs | 4 | ||||
| -rw-r--r-- | talpid-core/src/proxy/shadowsocks.rs | 2 | ||||
| -rw-r--r-- | talpid-core/src/tunnel/wireguard/wireguard_go.rs | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/mullvad-daemon/src/relays.rs b/mullvad-daemon/src/relays.rs index e9c02c6214..7590a9b2a8 100644 --- a/mullvad-daemon/src/relays.rs +++ b/mullvad-daemon/src/relays.rs @@ -322,11 +322,11 @@ impl RelaySelector { matching_relays.sort_by_cached_key(|relay| { (relay.location.as_ref().unwrap().distance_from(&location) * 1000.0) as i64 }); - return matching_relays.get(0).and_then(|relay| { + matching_relays.get(0).and_then(|relay| { (self .pick_random_bridge(&relay) .map(|bridge| (bridge, relay.clone()))) - }); + }) } diff --git a/talpid-core/src/proxy/shadowsocks.rs b/talpid-core/src/proxy/shadowsocks.rs index 91da5e3b59..890767a001 100644 --- a/talpid-core/src/proxy/shadowsocks.rs +++ b/talpid-core/src/proxy/shadowsocks.rs @@ -212,7 +212,7 @@ impl ShadowsocksProxyMonitor { })?); } - return Err(Error::new(ErrorKind::Other, "No port number present")); + Err(Error::new(ErrorKind::Other, "No port number present")) } } diff --git a/talpid-core/src/tunnel/wireguard/wireguard_go.rs b/talpid-core/src/tunnel/wireguard/wireguard_go.rs index f72371eb11..c86dfccce6 100644 --- a/talpid-core/src/tunnel/wireguard/wireguard_go.rs +++ b/talpid-core/src/tunnel/wireguard/wireguard_go.rs @@ -92,7 +92,7 @@ impl WgGoTunnel { return Err(Error::StopWireguardError { status }); } } - return Ok(()); + Ok(()) } } |
