fix(query): box transaction command errors

This commit is contained in:
t8y2 committed 2026-08-24 12:38:05 +08:00
1 parent e03cc2d269
commit 7e1e9053f8
1 file changed
+3 -3
+3 -3
View File
@@ -26,7 +26,7 @@ struct ExecuteMultiProgress {
#[derive(Debug, serde::Serialize)] #[derive(Debug, serde::Serialize)]
#[serde(untagged)] #[serde(untagged)]
pub enum ManualTransactionCommandError { pub enum ManualTransactionCommandError {
Structured(BackendError), Structured(Box<BackendError>),
Legacy(String), Legacy(String),
} }
@@ -476,9 +476,9 @@ pub async fn execute_in_manual_transaction(
.await .await
.map_err(|error| { .map_err(|error| {
if dbx_core::query::is_manual_transaction_session_expired_error(&error) { if dbx_core::query::is_manual_transaction_session_expired_error(&error) {
ManualTransactionCommandError::Structured(BackendError::from_manual_transaction_session_expired( ManualTransactionCommandError::Structured(Box::new(BackendError::from_manual_transaction_session_expired(
dbx_core::query::MANUAL_TRANSACTION_IDLE_TIMEOUT_SECS, dbx_core::query::MANUAL_TRANSACTION_IDLE_TIMEOUT_SECS,
)) )))
} else { } else {
ManualTransactionCommandError::Legacy(error) ManualTransactionCommandError::Legacy(error)
} }