From 433c9265035b60e081f88b8a3c7cc0fd339bef4d Mon Sep 17 00:00:00 2001 From: Rob Ede Date: Sun, 9 Jun 2024 23:08:20 +0100 Subject: [PATCH] chore: address clippy lints --- actix-cors/src/builder.rs | 2 +- actix-limitation/src/lib.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/actix-cors/src/builder.rs b/actix-cors/src/builder.rs index b1193de041..7aec5cea80 100644 --- a/actix-cors/src/builder.rs +++ b/actix-cors/src/builder.rs @@ -214,7 +214,7 @@ impl Cors { /// See [`Cors::allowed_methods`] for more info on allowed methods. pub fn allow_any_method(mut self) -> Cors { if let Some(cors) = cors(&mut self.inner, &self.error) { - cors.allowed_methods = ALL_METHODS_SET.clone(); + ALL_METHODS_SET.clone_into(&mut cors.allowed_methods); } self diff --git a/actix-limitation/src/lib.rs b/actix-limitation/src/lib.rs index 27d79d7b0e..3263a5973e 100644 --- a/actix-limitation/src/lib.rs +++ b/actix-limitation/src/lib.rs @@ -138,7 +138,7 @@ impl Limiter { let key = key.into(); let expires = self.period.as_secs(); - let mut connection = self.client.get_tokio_connection().await?; + let mut connection = self.client.get_multiplexed_tokio_connection().await?; // The seed of this approach is outlined Atul R in a blog post about rate limiting using // NodeJS and Redis. For more details, see https://blog.atulr.com/rate-limiter