From 1c4cfa680c6f57bc6a77b05210469710ef3bcf51 Mon Sep 17 00:00:00 2001 From: James Lu Date: Sat, 14 May 2016 13:52:21 -0700 Subject: [PATCH] log: fix check for irc.pseudoclient --- log.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/log.py b/log.py index e366ac9..c1dbd72 100644 --- a/log.py +++ b/log.py @@ -102,7 +102,7 @@ class PyLinkChannelLogger(logging.Handler): # 3) Target channel must exist # 4) Main PyLink client must be in this target channel # 5) This function hasn't been called already (prevents recursive loops). - if hasattr(self.irc, 'pseudoclient') and self.irc.connected.is_set() \ + if self.irc.pseudoclient and self.irc.connected.is_set() \ and self.channel in self.irc.channels and self.irc.pseudoclient.uid in \ self.irc.channels[self.channel].users and not self.called: