Skip to content

Commit

Permalink
Remove unused decoder (#64)
Browse files Browse the repository at this point in the history
  • Loading branch information
VojtechVitek authored Apr 17, 2024
1 parent edb53fa commit fc75708
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions client.go.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ func (c *{{$serviceNameClient}}) {{$method.Name}}(ctx context.Context{{range $_,
}

buf := bufio.NewReader(resp.Body)
return &{{$method.Name | firstLetterToLower}}StreamReader{streamReader{ctx: ctx, c: resp.Body, r: buf, d: json.NewDecoder(buf)}}, nil
return &{{$method.Name | firstLetterToLower}}StreamReader{streamReader{ctx: ctx, c: resp.Body, r: buf}}, nil
}

type {{firstLetterToLower $method.Name}}StreamReader struct {
Expand Down Expand Up @@ -134,7 +134,6 @@ type streamReader struct {
ctx context.Context
c io.Closer
r *bufio.Reader
d *json.Decoder
}

func (r *streamReader) read(v interface {}) error {
Expand Down

0 comments on commit fc75708

Please sign in to comment.