From 9ce55c6a13e34b4555c1f025d3c7bbd710c0cb82 Mon Sep 17 00:00:00 2001 From: Gabriel Date: Thu, 9 Nov 2023 11:46:29 -0500 Subject: [PATCH] Remove totally unnecessary DatabaseConnection clone --- server/svix-server/src/expired_message_cleaner.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/server/svix-server/src/expired_message_cleaner.rs b/server/svix-server/src/expired_message_cleaner.rs index 0288f2474..b5468dffd 100644 --- a/server/svix-server/src/expired_message_cleaner.rs +++ b/server/svix-server/src/expired_message_cleaner.rs @@ -67,8 +67,7 @@ pub async fn expired_message_cleaner_loop(pool: &DatabaseConnection) -> Result<( if let Some(duration) = sleep_time { sleep(duration).await; } - let pool = pool.clone(); - match clean_expired_messages(&pool, BATCH_SIZE).await { + match clean_expired_messages(pool, BATCH_SIZE).await { Err(err) => { tracing::error!("{}", err); }