feat(messages): message mutes are enabled
This commit is contained in:
parent
a95ad8a702
commit
28af26843a
|
@ -19,6 +19,12 @@ func sendEmailNotification(app *pocketbase.PocketBase, registry *template.Regist
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// don't send email notification if user has muted email notifications and message is not an announcement
|
||||||
|
if user.GetBool("muteEmailNotifications") && !message.GetBool("isAnnouncement") {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// get user email
|
||||||
userEmail := user.GetString("email")
|
userEmail := user.GetString("email")
|
||||||
|
|
||||||
// check if user has a valid email
|
// check if user has a valid email
|
||||||
|
|
Loading…
Reference in New Issue