From: kaliko Date: Tue, 21 Mar 2023 21:53:45 +0000 (+0100) Subject: rtbl: Fixed rtbl_ban call X-Git-Tag: 0.3.0~7 X-Git-Url: https://git.kaliko.me/?a=commitdiff_plain;h=1a3b109549f5aca715e912309742ea478d215c0a;p=sid.git rtbl: Fixed rtbl_ban call --- diff --git a/sid/rtbl.py b/sid/rtbl.py index 13e5c91..e5e4e6f 100644 --- a/sid/rtbl.py +++ b/sid/rtbl.py @@ -108,6 +108,9 @@ class RTBL(Plugin): self.blocklist = BL(node_blocklist['pubsub']['items']) mess = f'Got {len(self.blocklist)} items in block list' self.log.info(mess) + # Are current participants in the block list + for jid in list(self.participants): + await self.rtbl_ban(jid) async def _create(self): """Try to create node""" @@ -138,8 +141,8 @@ class RTBL(Plugin): return self.blocklist.insert_item(msg['pubsub_event']['items']['item']['id']) # Are current participants in the block list - for jid in self.participants: - self.rtbl_ban(jid) + for jid in list(self.participants): + await self.rtbl_ban(jid) async def rtbl_ban(self, jid): """Ban jid in RTBL"""