Skip to content

Commit

Permalink
fix: prefix with upper case letters
Browse files Browse the repository at this point in the history
  • Loading branch information
ldez committed Jul 18, 2022
1 parent 6f5cb16 commit 90933eb
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions pkg/section/parser.go
Expand Up @@ -25,10 +25,10 @@ func Parse(data []string) (SectionList, error) {
list = append(list, Standard{})
} else if s == "newline" {
list = append(list, NewLine{})
} else if strings.HasPrefix(s, "prefix(") && len(s) > 8 {
list = append(list, Custom{s[7 : len(s)-1]})
} else if strings.HasPrefix(s, "commentline(") && len(s) > 13 {
list = append(list, Custom{s[12 : len(s)-1]})
} else if strings.HasPrefix(s, "prefix(") && len(d) > 8 {
list = append(list, Custom{d[7 : len(d)-1]})
} else if strings.HasPrefix(s, "commentline(") && len(d) > 13 {
list = append(list, Custom{d[12 : len(d)-1]})
} else {
errString += fmt.Sprintf(" %s", s)
}
Expand Down

0 comments on commit 90933eb

Please sign in to comment.