(content string)
| 1000 | } |
| 1001 | |
| 1002 | func parseTitle(content string) string { |
| 1003 | for _, line := range strings.Split(content, "\n") { |
| 1004 | line = strings.TrimSpace(line) |
| 1005 | if strings.HasPrefix(line, "# ") { |
| 1006 | return strings.TrimSpace(strings.TrimPrefix(line, "# ")) |
| 1007 | } |
| 1008 | } |
| 1009 | return "" |
| 1010 | } |
| 1011 | |
| 1012 | func parseSections(content string) map[string]section { |
| 1013 | result := make(map[string]section) |
no outgoing calls
no test coverage detected