From e094de162ca9a93f5057b87e0dfc2db1f64634d9 Mon Sep 17 00:00:00 2001 From: "Michael P. Jung" Date: Mon, 3 Feb 2025 21:27:28 +0100 Subject: [PATCH] Fix elided_named_lifetimes warning --- postgres/src/generic_client.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/postgres/src/generic_client.rs b/postgres/src/generic_client.rs index 96f4855..a8396b4 100644 --- a/postgres/src/generic_client.rs +++ b/postgres/src/generic_client.rs @@ -81,7 +81,7 @@ pub trait GenericClient: Sync + private::Sealed { async fn prepare_typed_cached(&self, query: &str, types: &[Type]) -> Result; /// Like `Client::transaction`. - async fn transaction(&mut self) -> Result, Error>; + async fn transaction<'a>(&'a mut self) -> Result, Error>; /// Like `Client::batch_execute`. async fn batch_execute(&self, query: &str) -> Result<(), Error>; @@ -167,7 +167,7 @@ impl GenericClient for Client { ClientWrapper::prepare_typed_cached(self, query, types).await } - async fn transaction(&mut self) -> Result, Error> { + async fn transaction<'a>(&'a mut self) -> Result, Error> { ClientWrapper::transaction(self).await }