From 1f8ff8afe9bad1a5a9850e57ce82410b9c5f1aa9 Mon Sep 17 00:00:00 2001 From: valentinkolb Date: Thu, 24 Oct 2024 19:14:45 +0200 Subject: [PATCH] fix(emailApi): bug fix for expedition --- emailApi/main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emailApi/main.go b/emailApi/main.go index 12274ee..3dae715 100644 --- a/emailApi/main.go +++ b/emailApi/main.go @@ -62,7 +62,7 @@ func sendEmails(app *pocketbase.PocketBase, emailRecord *models.Record) { registry := template.NewRegistry() // expand the createdMessageRecord to get recipient user and send email notification if recipient is set - if errs := app.Dao().ExpandRecord(emailRecord, []string{"recipients, sender"}, nil); len(errs) > 0 { + if errs := app.Dao().ExpandRecord(emailRecord, []string{"recipients", "sender"}, nil); len(errs) > 0 { // return new error with all errors logger.LogErrorF("Error expanding created email record: %v", errs) emailRecord.Set("errors", fmt.Sprintf("The email was not sent to anyone due to an error."))