Skip to content

Commit 60329f6

Browse files
committed
fix handle error
1 parent 60a1b79 commit 60329f6

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

driver/src/conn.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -191,17 +191,17 @@ pub trait Connection: DynClone + Send + Sync {
191191
}
192192

193193
async fn begin(&self) -> Result<()> {
194-
let _ = self.exec("BEGIN").await;
194+
self.exec("BEGIN").await?;
195195
Ok(())
196196
}
197197

198198
async fn commit(&self) -> Result<()> {
199-
let _ = self.exec("COMMIT").await;
199+
self.exec("COMMIT").await?;
200200
Ok(())
201201
}
202202

203203
async fn rollback(&self) -> Result<()> {
204-
let _ = self.exec("ROLLBACK").await;
204+
self.exec("ROLLBACK").await?;
205205
Ok(())
206206
}
207207

driver/tests/driver/common/mod.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,5 @@
1212
// See the License for the specific language governing permissions and
1313
// limitations under the License.
1414

15-
pub static DEFAULT_DSN: &str = "databend://root:@localhost:8000/default?sslmode=disable";
15+
pub static DEFAULT_DSN: &str =
16+
"databend://databend:databend@localhost:8000/default?sslmode=disable";

0 commit comments

Comments
 (0)