callbacks: don't crash when the prefix is from network services.

This commit is contained in:
Valentin Lorentz 2020-07-25 15:29:16 +02:00
parent 5b52c73fd4
commit 8f72c418e5

View File

@ -1420,8 +1420,8 @@ class PluginMixin(BasePlugin, irclib.IrcCallback):
noIgnore = self.noIgnore noIgnore = self.noIgnore
if (noIgnore or if (noIgnore or
not msg.prefix or # simulated echo message not msg.prefix or # simulated echo message
not ircdb.checkIgnored(msg.prefix, msg.channel) or not ircutils.isUserHostmask(msg.prefix) or # Some services impl.
not ircutils.isUserHostmask(msg.prefix)): # Some services impl. not ircdb.checkIgnored(msg.prefix, msg.channel)):
self.__parent.__call__(irc, msg) self.__parent.__call__(irc, msg)
else: else:
self.__parent.__call__(irc, msg) self.__parent.__call__(irc, msg)