Skip to content

Commit 37773f9

Browse files
authored
fix typed error check (#295)
1 parent 81e4140 commit 37773f9

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

e2e/topic.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -121,9 +121,9 @@ func (s *Service) executeCreatePartitions(ctx context.Context, req *kmsg.CreateP
121121
}
122122

123123
for _, topic := range res.Topics {
124-
typedErr := kerr.TypedErrorForCode(topic.ErrorCode)
125-
if typedErr != nil {
126-
return fmt.Errorf("inner Kafka error: %w", typedErr)
124+
err := kerr.ErrorForCode(topic.ErrorCode)
125+
if err != nil {
126+
return fmt.Errorf("inner Kafka error: %w", err)
127127
}
128128
}
129129

0 commit comments

Comments
 (0)