完善error库

This commit is contained in:
hoteas 2021-05-29 00:41:17 +08:00
parent 0e2932ca89
commit 95489fcf49

View File

@ -42,7 +42,7 @@ func (that *HoTimeDB) GetType() string {
// Action 事务如果action返回true则执行成功false则回滚 // Action 事务如果action返回true则执行成功false则回滚
func (that *HoTimeDB) Action(action func(db HoTimeDB) bool) bool { func (that *HoTimeDB) Action(action func(db HoTimeDB) bool) bool {
db := HoTimeDB{DB: that.DB, HoTimeCache: that.HoTimeCache} db := HoTimeDB{DB: that.DB, HoTimeCache: that.HoTimeCache, Prefix: that.Prefix}
tx, err := db.Begin() tx, err := db.Begin()
if err != nil { if err != nil {
that.LastErr.SetError(err) that.LastErr.SetError(err)