优化本地数据库关闭相关代码

This commit is contained in:
GoEdgeLab
2023-06-23 21:50:34 +08:00
parent 5749a37dce
commit caf08688e3

View File

@@ -151,6 +151,7 @@ func (this *Batch) beginTx() *sql.Tx {
tx, err := this.db.Begin()
if err != nil {
this.processErr("begin transaction", err)
this.db.EndUpdating()
return nil
}
return tx