From 5b561b51f420edf35a402369183767c2a69b09ae Mon Sep 17 00:00:00 2001 From: jesopo Date: Wed, 13 Feb 2019 10:56:52 +0000 Subject: [PATCH] Fix completely broken chghost code. What on god's earth was I thinking. --- modules/line_handler.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/modules/line_handler.py b/modules/line_handler.py index 44bbf7c0..62b1c07f 100644 --- a/modules/line_handler.py +++ b/modules/line_handler.py @@ -630,11 +630,12 @@ class Module(ModuleManager.BaseModule): # IRCv3 CHGHOST, a user's username and/or hostname has changed @utils.hook("raw.received.chghost") def chghost(self, event): + nickname = event["prefix"].nickname username = event["args"][0] hostname = event["args"][1] - if not event["server"].is_own_nickname(event["prefix"].nickname): - target = event["server"].get_user("nickanme") + if not event["server"].is_own_nickname(nickname): + target = event["server"].get_user(nickname) else: target = event["server"] target.username = username