1
0

feat!: make license case sensitive again (35181db)

BREAKING CHANGE: This feature causes errors for licenses
such as BSD-3-Clause, where 'Clause' is case sensitive.
This commit is contained in:
Wiktor Zykubek 2024-12-29 06:03:41 +01:00
parent 39bd97487b
commit 065606ee33
Signed by: wzykubek
GPG Key ID: 2221881F957D89B9

View File

@ -18,8 +18,7 @@ type Licenser struct {
} }
func (l *Licenser) ParseTemplate() (LicenseTemplate, error) { func (l *Licenser) ParseTemplate() (LicenseTemplate, error) {
licenseID := strings.ToUpper(l.LicenseID) tmplPath := "templates/" + l.LicenseID + ".tmpl"
tmplPath := "templates/" + licenseID + ".tmpl"
data, err := TemplatesDir.ReadFile(tmplPath) data, err := TemplatesDir.ReadFile(tmplPath)
if err != nil { if err != nil {
return LicenseTemplate{}, err return LicenseTemplate{}, err