mirror of
https://github.com/go-micro/go-micro.git
synced 2024-12-30 10:10:44 +02:00
Fix codec/bytes (#2466)
* Update marshaler.go Byes codec always return error "invalid message" now. * Update go.mod Update package name * Update go.mod
This commit is contained in:
parent
1f086a3002
commit
d1806e2883
@ -27,8 +27,10 @@ func (n Marshaler) Unmarshal(d []byte, v interface{}) error {
|
||||
switch ve := v.(type) {
|
||||
case *[]byte:
|
||||
*ve = d
|
||||
return nil
|
||||
case *Message:
|
||||
ve.Body = d
|
||||
return nil
|
||||
}
|
||||
return codec.ErrInvalidMessage
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user