From 1ad2d0ad8752249d72786c3457cf683a51e3efe4 Mon Sep 17 00:00:00 2001 From: Jiahao XU Date: Mon, 3 Jun 2024 23:45:38 +1000 Subject: [PATCH] Fix clippy lints Signed-off-by: Jiahao XU --- crates/binstalk-downloader/src/download.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/crates/binstalk-downloader/src/download.rs b/crates/binstalk-downloader/src/download.rs index 57250b94..caf9b2f8 100644 --- a/crates/binstalk-downloader/src/download.rs +++ b/crates/binstalk-downloader/src/download.rs @@ -97,7 +97,7 @@ enum DownloadContent { } impl DownloadContent { - async fn to_response(self) -> Result { + async fn into_response(self) -> Result { Ok(match self { DownloadContent::ToIssue { client, url } => client.get(url).send(true).await?, DownloadContent::Response(response) => response, @@ -163,7 +163,7 @@ impl<'a> Download<'a> { let mut data_verifier = self.data_verifier; Ok(self .content - .to_response() + .into_response() .await? .bytes_stream() .map(move |res| { @@ -272,7 +272,7 @@ impl Download<'_> { #[instrument] pub async fn into_bytes(self) -> Result { - let bytes = self.content.to_response().await?.bytes().await?; + let bytes = self.content.into_response().await?.bytes().await?; if let Some(verifier) = self.data_verifier { verifier.update(&bytes); }