1
0
mirror of https://github.com/astaxie/beego.git synced 2024-11-26 03:01:28 +00:00
This commit is contained in:
BaoyangChai 2019-06-28 22:56:32 +08:00
parent 06692c3e27
commit 5d0c0a03d7

View File

@ -172,7 +172,6 @@ func (d *DB) QueryRow(query string, args ...interface{}) *sql.Row {
stmt, err := d.getStmt(query) stmt, err := d.getStmt(query)
if err != nil { if err != nil {
panic(err) panic(err)
return nil
} }
return stmt.QueryRow(args...) return stmt.QueryRow(args...)
@ -183,7 +182,6 @@ func (d *DB) QueryRowContext(ctx context.Context, query string, args ...interfac
stmt, err := d.getStmt(query) stmt, err := d.getStmt(query)
if err != nil { if err != nil {
panic(err) panic(err)
return nil
} }
return stmt.QueryRowContext(ctx, args) return stmt.QueryRowContext(ctx, args)
} }