1
0
mirror of https://github.com/ipfs/kubo.git synced 2025-06-30 18:13:54 +08:00

object put: Added plaintext marshaler

This commit is contained in:
Matt Bell
2014-11-14 00:07:46 -08:00
committed by Juan Batiz-Benet
parent b4de6cce9a
commit fceb55ef1e

View File

@ -221,6 +221,12 @@ Data should be in the format specified by <encoding>.
return output, nil
},
Marshalers: cmds.MarshalerMap{
cmds.Text: func(res cmds.Response) ([]byte, error) {
object := res.Output().(*Object)
return []byte(object.Hash), nil
},
},
Type: &Object{},
}