From a729b37b224744fcd5bcf71695fedb4849474b1f Mon Sep 17 00:00:00 2001 From: Yusuf Bera Ertan Date: Wed, 26 May 2021 16:07:54 +0300 Subject: [PATCH] Update src/client.rs Co-authored-by: Daniel Abramov --- src/client.rs | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/client.rs b/src/client.rs index 2a6a513..55ba080 100644 --- a/src/client.rs +++ b/src/client.rs @@ -72,10 +72,7 @@ mod encryption { Mode::Tls => { let config = { let mut config = ClientConfig::new(); - config.root_store = match rustls_native_certs::load_native_certs() { - Ok(store) => store, - Err((_, err)) => Err(err)?, - }; + config.root_store = rustls_native_certs::load_native_certs().map_err(|(_, err)| err)?; Arc::new(config) };