func (command *commandUpdateMetadata) PreCSV(resource *handler.Resource) { resource.Result = map[string]interface{}{ "Metadata": resource.Result, } resource.Keys = []string{"Metadata"} resource.FlattenMap("Metadata") }
func (command *commandSetMetadata) PreCSV(resource *handler.Resource) error { resource.Result = map[string]interface{}{ "Metadata": resource.Result, } resource.Keys = []string{"Metadata"} resource.FlattenMap("Metadata") return nil }
func (command *commandAbandon) PreJSON(resource *handler.Resource) error { var resInterface map[string]interface{} res, err := json.Marshal(resource.Result) if err != nil { return err } err = json.Unmarshal(res, &resInterface) if err != nil { return err } resource.Result = resInterface resource.Keys = []string{"status", "name", "template", "action", "id", "resources", "files", "stack_user_project_id", "project_id", "environment"} return nil }