with_transaction

Function with_transaction 

Source
pub async fn with_transaction<F, T>(pool: &DbPool, f: F) -> Result<T>
where F: for<'a> FnOnce(&'a mut Transaction<'_>) -> Pin<Box<dyn Future<Output = Result<T>> + Send + 'a>>, T: Send,