From d90f44c510f935634dc86262c82eec6c3d876917 Mon Sep 17 00:00:00 2001 From: James Lu Date: Sun, 20 Nov 2016 12:04:30 -0800 Subject: [PATCH] changehost: explicitly ignore PyLink internal clients --- plugins/changehost.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/plugins/changehost.py b/plugins/changehost.py index 89758c6..d5553b5 100644 --- a/plugins/changehost.py +++ b/plugins/changehost.py @@ -16,6 +16,12 @@ allowed_chars = string.ascii_letters + '-./:' + string.digits def _changehost(irc, target, args): changehost_conf = conf.conf.get("changehost") + if target not in irc.users: + return + elif irc.isInternalClient(target): + log.debug('(%s) Skipping changehost on internal client %s', irc.name, target) + return + if not changehost_conf: log.warning("(%s) Missing 'changehost:' configuration block; " "Changehost will not function correctly!", irc.name)