From fceb55ef1ea0e6fb3c56d4406ab8047727d0b3b6 Mon Sep 17 00:00:00 2001 From: Matt Bell Date: Fri, 14 Nov 2014 00:07:46 -0800 Subject: [PATCH] object put: Added plaintext marshaler --- core/commands2/object.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/core/commands2/object.go b/core/commands2/object.go index ef4242ce9..63ceb903b 100644 --- a/core/commands2/object.go +++ b/core/commands2/object.go @@ -221,6 +221,12 @@ Data should be in the format specified by . 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{}, }