From 34b318d3384fd7a915c98e92503bc06185e1bab7 Mon Sep 17 00:00:00 2001 From: Karan Gauswami Date: Sat, 20 Nov 2021 18:10:26 +0530 Subject: [PATCH] ran cargo clippy --- src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.rs b/src/main.rs index e4492b7..b1a62b3 100644 --- a/src/main.rs +++ b/src/main.rs @@ -43,7 +43,7 @@ async fn main() -> Result<()> { Ok(()) } fn host_addr(uri: &http::Uri) -> Option { - uri.authority().and_then(|auth| Some(auth.to_string())) + uri.authority().map(|auth| auth.to_string()) } async fn proxy(req: Request, socks_address: SocketAddr) -> Result> { let mut connector = HttpConnector::new();