Skip to content

Commit 7c27cae

Browse files
committed
Remove hasUsefulContent function
1 parent 9bb5df8 commit 7c27cae

1 file changed

Lines changed: 0 additions & 12 deletions

File tree

cmd/go-yaml/main.go

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -287,13 +287,6 @@ Examples:
287287
`)
288288
}
289289

290-
// hasUsefulContent checks if a node has meaningful content to display.
291-
// Stream nodes are only returned when explicitly requested via -o stream,
292-
// so we always show them when present.
293-
func hasUsefulContent(n *yaml.Node) bool {
294-
return true
295-
}
296-
297290
// buildOptions creates the yaml.Option slice based on config file and -o flags
298291
func buildOptions(configFile string, optionFlags []string) ([]yaml.Option, error) {
299292
var opts []yaml.Option
@@ -558,11 +551,6 @@ func main() {
558551
log.Fatal("Failed to load YAML node:", err)
559552
}
560553

561-
// Skip stream nodes without useful content (use -o stream to show all)
562-
if !hasUsefulContent(&node) {
563-
continue
564-
}
565-
566554
var info any
567555
if profuse {
568556
info = FormatNode(node, profuse)

0 commit comments

Comments
 (0)