README: fix code example
@@ -65,7 +65,7 @@ ctx := context.Background()
var wg sync.WaitGroup
wg.Add(1)
record := &kgo.Record{Topic: "foo", Value: []byte("bar")}
-cl.Produce(ctx, record, func(_ *Record, err error) {
+cl.Produce(ctx, record, func(_ *kgo.Record, err error) {
defer wg.Done()
if err != nil {
fmt.Printf("record had a produce error: %v\n", err)
@@ -102,7 +102,7 @@ for {
}
// We can even use a second callback!
- p.EachRecord(func(record *Record) {
+ p.EachRecord(func(record *kgo.Record) {
fmt.Println(string(record.Value), "from a second callback!")
})
})
