Skip to content

Commit

Permalink
Improve HTML check in notif template loading. Closes knadh#903.
Browse files Browse the repository at this point in the history
  • Loading branch information
knadh committed Sep 10, 2022
1 parent f266f93 commit edb4c91
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cmd/init.go
Original file line number Diff line number Diff line change
Expand Up @@ -615,7 +615,7 @@ func initNotifTemplates(path string, fs stuffbin.FileSystem, i *i18n.I18n, cs *c
h := make([]byte, ln)
copy(h, html[0:ln])

if !bytes.Contains(bytes.ToLower(h), []byte("<!doctype html>")) {
if !bytes.Contains(bytes.ToLower(h), []byte("<!doctype html")) {
out.contentType = models.CampaignContentTypePlain
lo.Println("system e-mail templates are plaintext")
}
Expand Down

0 comments on commit edb4c91

Please sign in to comment.