From ec9473fa780ea914882d0c6d7d8125b8107a6d09 Mon Sep 17 00:00:00 2001 From: Edward Shen Date: Sun, 11 Jul 2021 23:25:17 -0400 Subject: [PATCH] clippy lint --- src/routes.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/routes.rs b/src/routes.rs index c048afb..b6eb6dd 100644 --- a/src/routes.rs +++ b/src/routes.rs @@ -119,9 +119,9 @@ pub async fn default(state: Data, req: HttpRequest) -> impl R } // push_headers(&mut resp_builder); - let mut ret = resp_builder.body(resp.bytes().await.unwrap_or_default()); - *ret.headers_mut() = headers; - ServerResponse::HttpResponse(ret) + let mut resp = resp_builder.body(resp.bytes().await.unwrap_or_default()); + *resp.headers_mut() = headers; + ServerResponse::HttpResponse(resp) } #[allow(clippy::future_not_send, clippy::unused_async)]