mirror of
https://github.com/launchbadge/sqlx.git
synced 2025-12-29 21:00:54 +00:00
Run rustfmt
This commit is contained in:
parent
0fdc4c4761
commit
6ddf3184de
@ -1,8 +1,7 @@
|
||||
//! **Pool** for SQLx database connections.
|
||||
|
||||
use std::{
|
||||
fmt,
|
||||
mem,
|
||||
fmt, mem,
|
||||
ops::{Deref, DerefMut},
|
||||
sync::Arc,
|
||||
time::{Duration, Instant},
|
||||
|
||||
@ -4,10 +4,10 @@ use async_std::task;
|
||||
use futures_core::future::BoxFuture;
|
||||
use futures_core::stream::BoxStream;
|
||||
|
||||
use crate::connection::Connection;
|
||||
use crate::database::Database;
|
||||
use crate::describe::Describe;
|
||||
use crate::executor::Executor;
|
||||
use crate::connection::Connection;
|
||||
|
||||
pub struct Transaction<T>
|
||||
where
|
||||
@ -96,15 +96,13 @@ where
|
||||
}
|
||||
}
|
||||
|
||||
impl<T> Connection for Transaction<T>
|
||||
where
|
||||
T: Connection
|
||||
impl<T> Connection for Transaction<T>
|
||||
where
|
||||
T: Connection,
|
||||
{
|
||||
// Close is equivalent to ROLLBACK followed by CLOSE
|
||||
fn close(self) -> BoxFuture<'static, crate::Result<()>> {
|
||||
Box::pin(async move {
|
||||
self.rollback().await?.close().await
|
||||
})
|
||||
Box::pin(async move { self.rollback().await?.close().await })
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user