From ebd7f24f41d87e443bb4ecfaff6d6441b3343baa Mon Sep 17 00:00:00 2001 From: "Vgr E. Barry" Date: Sat, 30 Dec 2017 09:51:59 -0500 Subject: [PATCH] Updating the event_hosthidden handler --- src/hooks.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/hooks.py b/src/hooks.py index 480bd9f..a21e492 100644 --- a/src/hooks.py +++ b/src/hooks.py @@ -175,8 +175,13 @@ def host_hidden(cli, server, nick, host, message): """ - assert nick == users.Bot.nick - users.Bot = users.Bot.with_host(host) + # Either we get our own nick, or the nick is a UID + # If it's our nick, update ourself. Otherwise, ignore + # UnrealIRCd does some weird stuff where it sends our host twice, + # Once with our nick and once with our UID. We ignore the last one + + if nick == users.Bot.nick: + users.Bot = users.Bot.with_host(host) ### Server PING handling