diff --git a/prometheus_xmpp/__main__.py b/prometheus_xmpp/__main__.py index d9266f1..78774db 100755 --- a/prometheus_xmpp/__main__.py +++ b/prometheus_xmpp/__main__.py @@ -242,15 +242,8 @@ async def dispatch_message(self, mto, mbody, mhtml): return_exceptions=True, ) muc_affiliation = owners + admins + members + outcasts - logging.debug(f"MUC_AFFILIATION: {muc_affiliation}") - recipients = [] - for nick in muc_affiliation: - recipients.append(JID(nick)) + recipients = [JID(nick) for nick in muc_affiliations] logging.debug(f"sending encrypted message to recipients: {recipients}") - # for nick in muc_affiliation: - # recipients.append( - # JID(self.plugin["xep_0045"].get_jid_property(mto, nick, "jid")) - # ) await self.send_encrypted(mto=recipients, mtype="groupchat", body=mbody) async def send_encrypted(self, mto: JID, mtype: str, body):