set username and hostmask on chghost before event dispatch
This commit is contained in:
parent
96a74747dc
commit
e79e3f0315
1 changed files with 5 additions and 2 deletions
|
@ -73,12 +73,15 @@ def chghost(events, event):
|
|||
event["server"].hostname = hostname
|
||||
|
||||
target = event["server"].get_user(nickname)
|
||||
events.on("received.chghost").call(user=target, server=event["server"],
|
||||
username=username, hostname=hostname)
|
||||
|
||||
old_username = target.username
|
||||
old_hostname = target.hostname
|
||||
target.username = username
|
||||
target.hostname = hostname
|
||||
|
||||
events.on("received.chghost").call(user=target, server=event["server"],
|
||||
old_username=old_username, old_hostname=old_hostname)
|
||||
|
||||
def setname(event):
|
||||
nickname = event["line"].source.nickname
|
||||
realname = event["line"].args[0]
|
||||
|
|
Loading…
Reference in a new issue