accounts: fix announcements preview window

since the "Announcement" template doesn't actually exist, finding it in
the DB would fail, which is now ignored.
pull/298/head
Harvey Tindall 1 year ago
parent d8d478a95e
commit 4ea2dfdfb7
No known key found for this signature in database
GPG Key ID: BBC65952848FB1A2

@ -162,7 +162,7 @@ func (app *appContext) GetCustomMessageTemplate(gc *gin.Context) {
username := app.storage.lang.Email[lang].Strings.get("username") username := app.storage.lang.Email[lang].Strings.get("username")
emailAddress := app.storage.lang.Email[lang].Strings.get("emailAddress") emailAddress := app.storage.lang.Email[lang].Strings.get("emailAddress")
customMessage, ok := app.storage.GetCustomContentKey(id) customMessage, ok := app.storage.GetCustomContentKey(id)
if !ok { if !ok && id != "Announcement" {
app.err.Printf("Failed to get custom message with ID \"%s\"", id) app.err.Printf("Failed to get custom message with ID \"%s\"", id)
respondBool(400, false, gc) respondBool(400, false, gc)
return return

Loading…
Cancel
Save