Merge pull request #27019 from anupamvs/email-digest-fix-pre

fix: email digest recipient patch
This commit is contained in:
rohitwaghchaure
2021-08-19 11:49:49 +05:30
committed by GitHub

View File

@@ -11,6 +11,7 @@ def execute():
for email_digest in email_digests: for email_digest in email_digests:
if email_digest.recipient_list: if email_digest.recipient_list:
for recipient in email_digest.recipient_list.split("\n"): for recipient in email_digest.recipient_list.split("\n"):
if frappe.db.exists('User', recipient):
doc = frappe.get_doc({ doc = frappe.get_doc({
'doctype': 'Email Digest Recipient', 'doctype': 'Email Digest Recipient',
'parenttype': 'Email Digest', 'parenttype': 'Email Digest',