diff --git a/internal/client/granularflow2pX.go b/internal/client/granularflow2pX.go index 8cf5d3a..4fb0293 100644 --- a/internal/client/granularflow2pX.go +++ b/internal/client/granularflow2pX.go @@ -290,10 +290,8 @@ func (c *protocolConnection) codecsFromIDsV2( return nil, nil } - in, err = codecs.BuildEncoderV2( - desc.(*descriptor.V2), - c.protocolVersion, - ) + d := desc.(descriptor.V2) + in, err = codecs.BuildEncoderV2(&d, c.protocolVersion) if err != nil { return nil, &invalidArgumentError{msg: err.Error()} }