Skip to content

Commit

Permalink
fix: Fix Email notifications to multiple email addresses (#1437)
Browse files Browse the repository at this point in the history
Previously, sending notifications to multiple email addresses (not users) at once didn't work.
  • Loading branch information
baumandm authored Apr 12, 2024
1 parent 4c74ac8 commit 2dbc30d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions querybook/server/lib/notify/notifier/email_notifier.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,11 @@ def notify_recipients(self, recipients, message):
msg["Subject"] = subject
msg["Date"] = date
msg["From"] = from_email
msg["To"] = ",".join(recipients)
msg["To"] = ", ".join(recipients)
msg.attach(MIMEText(message, "html"))

smtp = smtplib.SMTP(QuerybookSettings.EMAILER_CONN)
smtp.sendmail(msg["From"], msg["To"], msg.as_string())
smtp.sendmail(msg["From"], recipients, msg.as_string())
except Exception as e:
LOG.info(e)

Expand Down

0 comments on commit 2dbc30d

Please sign in to comment.