diff --git a/pgxpool/pool.go b/pgxpool/pool.go index b7c949e5..6d24766a 100644 --- a/pgxpool/pool.go +++ b/pgxpool/pool.go @@ -680,7 +680,7 @@ func (p *Pool) BeginTx(ctx context.Context, txOptions pgx.TxOptions) (pgx.Tx, er return nil, err } - return &Tx{t: t, c: c}, err + return &Tx{t: t, c: c}, nil } func (p *Pool) BeginFunc(ctx context.Context, f func(pgx.Tx) error) error {