From a550bf07ac0e9b829859871ef667e34fa6e271a8 Mon Sep 17 00:00:00 2001 From: Brian Stephan Date: Thu, 6 May 2021 09:29:26 -0500 Subject: [PATCH] discard from set to ignore KeyError --- history/ircplugin.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/history/ircplugin.py b/history/ircplugin.py index 619103b..3fbb6bd 100644 --- a/history/ircplugin.py +++ b/history/ircplugin.py @@ -152,7 +152,7 @@ class History(Plugin): def _remove_channel_participant(self, where, who): """Remove the specified who from the where channel's participants list.""" participants = self.channel_participants.setdefault(where, set()) - participants.remove(who) + participants.discard(who) logger.debug("participants for %s: %s", where, participants)