From 10349c61b51cce0bad43f044299c63061614c5c8 Mon Sep 17 00:00:00 2001 From: MATILLAT Quentin Date: Wed, 29 Jan 2025 15:03:53 +0100 Subject: [PATCH] chore!: Remove ref from http_client in constructors Signed-off-by: MATILLAT Quentin --- src/lib.rs | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index 94ed56a..bf3c15e 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -184,7 +184,7 @@ impl OidcClient { client_id, client_secret, scopes, - &client, + client, ) .await } @@ -198,18 +198,17 @@ impl OidcClient { client_id: String, client_secret: Option, scopes: Vec, - //TODO remove borrow with next breaking version - client: &reqwest::Client, + client: reqwest::Client, ) -> Result { let provider_metadata = - ProviderMetadata::discover_async(IssuerUrl::new(issuer)?, client).await?; + ProviderMetadata::discover_async(IssuerUrl::new(issuer)?, &client).await?; Self::from_provider_metadata_and_client( provider_metadata, application_base_url, client_id, client_secret, scopes, - client.clone(), + client, ) } }