Stop treating top-level values specially

This commit is contained in:
koba-e964 2019-11-03 15:51:14 +09:00
parent b6da773dde
commit a865d66b4f

7
yq.go
View File

@ -600,12 +600,7 @@ func toString(context interface{}) (string, error) {
}
func yamlToString(context interface{}) (string, error) {
switch context := context.(type) {
case string:
return context, nil
default:
return marshalContext(context)
}
return marshalContext(context)
}
func marshalContext(context interface{}) (string, error) {