From 4067ea31e09f4f2a2646773be60818490c9e403c Mon Sep 17 00:00:00 2001 From: Evert Prants Date: Sat, 8 Feb 2020 13:04:05 +0200 Subject: [PATCH] Fix NICK --- src/js/irc.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/js/irc.js b/src/js/irc.js index b980a35..4458547 100644 --- a/src/js/irc.js +++ b/src/js/irc.js @@ -458,12 +458,13 @@ class IRCConnectionHandler { } break case 'NICK': + let newNickA = line.arguments[0] || line.trailing if (line.user.nickname === this.conn.config.nickname) { - this.conn.config.nickname = line.arguments[0] + this.conn.config.nickname = newNickA } this.conn.emit('fromServer', { - type: 'nick', nick: line.user.nickname, newNick: line.arguments[0], server: serverName + type: 'nick', nick: line.user.nickname, newNick: newNickA, server: serverName }) break case 'KICK':