diff --git a/frappe/desk/doctype/event/event.py b/frappe/desk/doctype/event/event.py index 5463df6413..bf56498780 100644 --- a/frappe/desk/doctype/event/event.py +++ b/frappe/desk/doctype/event/event.py @@ -121,9 +121,7 @@ class Event(Document): ["Communication Link", "link_doctype", "=", participant.reference_doctype], ["Communication Link", "link_name", "=", participant.reference_docname], ] - comms = frappe.get_all("Communication", filters=filters, fields=["name"]) - - if comms: + if comms := frappe.get_all("Communication", filters=filters, fields=["name"], distinct=True): for comm in comms: communication = frappe.get_doc("Communication", comm.name) self.update_communication(participant, communication)