From 76a0eb78e3058d26d1da48a61504ca12a75be37a Mon Sep 17 00:00:00 2001 From: James Lu Date: Sat, 23 Sep 2017 21:54:42 -0700 Subject: [PATCH] clientbot: fix possible TypeError in squit() --- protocols/clientbot.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/protocols/clientbot.py b/protocols/clientbot.py index e5eb627..7e3cf92 100644 --- a/protocols/clientbot.py +++ b/protocols/clientbot.py @@ -312,7 +312,7 @@ class ClientbotWrapperProtocol(IRCCommonProtocol): # Removing pseudoclients and pseudoservers. squit_data = self._squit(source, 'CLIENTBOT_VIRTUAL_SQUIT', [target, text]) - if squit_data.get('nicks'): + if squit_data and squit_data.get('nicks'): self.call_hooks([source, 'CLIENTBOT_SQUIT', squit_data]) def _stub(self, *args):