(node *yaml.Node)
| 125 | } |
| 126 | |
| 127 | func yamlScalarString(node *yaml.Node) string { |
| 128 | if node == nil || node.Kind == 0 { |
| 129 | return "" |
| 130 | } |
| 131 | if node.Kind == yaml.ScalarNode { |
| 132 | return strings.TrimSpace(node.Value) |
| 133 | } |
| 134 | var value string |
| 135 | if errDecode := node.Decode(&value); errDecode != nil { |
| 136 | return "" |
| 137 | } |
| 138 | return strings.TrimSpace(value) |
| 139 | } |
| 140 | |
| 141 | func yamlMappingValue(node *yaml.Node, key string) *yaml.Node { |
| 142 | if node == nil || node.Kind != yaml.MappingNode { |
no outgoing calls
no test coverage detected