Undo changes to client function obj

This commit is contained in:
Soam Vasani
2016-09-22 01:11:17 -07:00
parent 79fb54820e
commit 9a65c8a6fb
+2
View File
@@ -179,7 +179,9 @@ func (c *Client) FunctionGetRaw(m *fission.Metadata) ([]byte, error) {
}
func (c *Client) FunctionUpdate(f *fission.Function) (*fission.Metadata, error) {
orig := f.Code
f.Code = base64.StdEncoding.EncodeToString([]byte(f.Code))
defer func() { f.Code = orig }()
reqbody, err := json.Marshal(f)
if err != nil {