1
0
mirror of https://github.com/go-micro/go-micro.git synced 2025-06-12 22:07:47 +02:00

fix the tunnel execution

This commit is contained in:
Asim Aslam
2019-08-11 18:11:33 +01:00
parent 113d87d855
commit d0d729a789
5 changed files with 34 additions and 6 deletions

View File

@ -16,6 +16,7 @@ type rpcRequest struct {
body []byte
rawBody interface{}
stream bool
first bool
}
type rpcMessage struct {
@ -54,9 +55,9 @@ func (r *rpcRequest) Body() interface{} {
func (r *rpcRequest) Read() ([]byte, error) {
// got a body
if r.body != nil {
if r.first {
b := r.body
r.body = nil
r.first = false
return b, nil
}