Pārlūkot izejas kodu

fix bug that empty query in transaction (#801)

Kevin Wan 3 gadi atpakaļ
vecāks
revīzija
5b22823018
1 mainītis faili ar 2 papildinājumiem un 1 dzēšanām
  1. 2 1
      core/stores/sqlx/tx.go

+ 2 - 1
core/stores/sqlx/tx.go

@@ -30,7 +30,8 @@ func (t txSession) Prepare(q string) (StmtSession, error) {
 	}
 
 	return statement{
-		stmt: stmt,
+		query: q,
+		stmt:  stmt,
 	}, nil
 }