fix(minor): consider only email id as sender email for auto email report (#18231)

This commit is contained in:
Ritwik Puri 2022-09-27 13:46:30 +05:30 committed by GitHub
parent 13e6aca115
commit 43101e0356
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -40,8 +40,7 @@ class AutoEmailReport(Document):
@property
def sender_email(self):
email_id, login_id = frappe.db.get_value("Email Account", self.sender, ["email_id", "login_id"])
return login_id if login_id else email_id
return frappe.db.get_value("Email Account", self.sender, "email_id")
def validate_emails(self):
"""Cleanup list of emails"""