diff --git a/spanner/integration_test.go b/spanner/integration_test.go index 7ad2b82268f0..84d3872e8e22 100644 --- a/spanner/integration_test.go +++ b/spanner/integration_test.go @@ -924,7 +924,7 @@ func TestIntegration_BatchWrite(t *testing.T) { w.row) ms := make([]*Mutation, 1) ms[0] = m - mgs[i] = &MutationGroup{mutations: ms} + mgs[i] = &MutationGroup{Mutations: ms} } // Records the mutation group indexes received in the response. seen := make(map[int32]int32) diff --git a/spanner/mutation.go b/spanner/mutation.go index 80a992e6c2cf..eb9baba7b857 100644 --- a/spanner/mutation.go +++ b/spanner/mutation.go @@ -143,8 +143,8 @@ type Mutation struct { // A MutationGroup is a list of Mutation to be committed atomically. type MutationGroup struct { - // The mutations in this group - mutations []*Mutation + // The Mutations in this group + Mutations []*Mutation } // mapToMutationParams converts Go map into mutation parameters. @@ -444,7 +444,7 @@ func mutationsProto(ms []*Mutation) ([]*sppb.Mutation, error) { func mutationGroupsProto(mgs []*MutationGroup) ([]*sppb.BatchWriteRequest_MutationGroup, error) { gs := make([]*sppb.BatchWriteRequest_MutationGroup, 0, len(mgs)) for _, mg := range mgs { - ms, err := mutationsProto(mg.mutations) + ms, err := mutationsProto(mg.Mutations) if err != nil { return nil, err }