We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
impl Debug for PoolConnection
1 parent 3ab3029 commit e33d23eCopy full SHA for e33d23e
sqlx-core/src/pool/connection.rs
@@ -48,8 +48,10 @@ const EXPECT_MSG: &str = "BUG: inner connection already taken!";
48
49
impl<DB: Database> Debug for PoolConnection<DB> {
50
fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result {
51
- // TODO: Show the type name of the connection ?
52
- f.debug_struct("PoolConnection").finish()
+ f.debug_struct("PoolConnection")
+ .field("database", &DB::NAME)
53
+ .field("id", &self.live.as_ref().map(|live| live.id))
54
+ .finish()
55
}
56
57
0 commit comments