parseBoolFromFrontmatter extracts a boolean value from a frontmatter map. Returns false if the key is absent, the map is nil, or the value is not a bool.
(m map[string]any, key string)
| 26 | // parseBoolFromFrontmatter extracts a boolean value from a frontmatter map. |
| 27 | // Returns false if the key is absent, the map is nil, or the value is not a bool. |
| 28 | func parseBoolFromFrontmatter(m map[string]any, key string) bool { |
| 29 | return typeutil.ParseBool(m, key) |
| 30 | } |
| 31 | |
| 32 | // FileReader is a function type that reads file content |
| 33 | // This abstraction allows for different file reading strategies (disk, GitHub API, in-memory, etc.) |
no test coverage detected