2
0

Run gofmt with simplify flag

This commit is contained in:
ferhat elmas
2017-12-21 23:45:26 +01:00
parent cbb3fa5ecc
commit 763deea17e
25 changed files with 224 additions and 224 deletions
+1 -1
View File
@@ -370,7 +370,7 @@ func (c *Conn) Ping(ctx context.Context) error {
// text format so that pgx.Rows.Values doesn't decode it into a native type
// (e.g. []int32)
func restrictBinaryToDatabaseSqlTypes(ps *pgx.PreparedStatement) {
for i, _ := range ps.FieldDescriptions {
for i := range ps.FieldDescriptions {
intrinsic, _ := databaseSqlOIDs[ps.FieldDescriptions[i].DataType]
if !intrinsic {
ps.FieldDescriptions[i].FormatCode = pgx.TextFormatCode
+1 -1
View File
@@ -1208,7 +1208,7 @@ func TestStmtQueryContextCancel(t *testing.T) {
}),
pgmock.SendMessage(&pgproto3.ReadyForQuery{TxStatus: 'I'}),
pgmock.ExpectMessage(&pgproto3.Bind{PreparedStatement: "pgx_0", ParameterFormatCodes: []int16{1}, Parameters: [][]uint8{[]uint8{0x0, 0x0, 0x0, 0x2a}}, ResultFormatCodes: []int16{1}}),
pgmock.ExpectMessage(&pgproto3.Bind{PreparedStatement: "pgx_0", ParameterFormatCodes: []int16{1}, Parameters: [][]uint8{{0x0, 0x0, 0x0, 0x2a}}, ResultFormatCodes: []int16{1}}),
pgmock.ExpectMessage(&pgproto3.Execute{}),
pgmock.ExpectMessage(&pgproto3.Sync{}),