Cleaner nick detection in WALLOPS
authorCory Chaplin <cory.chaplin@laposte.net>
Wed, 14 May 2014 09:05:27 +0000 (11:05 +0200)
committerCory Chaplin <cory.chaplin@laposte.net>
Wed, 14 May 2014 09:05:27 +0000 (11:05 +0200)
server/irc/commands.js

index 72e6b5de5b52838d30f29beb2eca81660f257898..50b85c9e7305fba0a1000038d22c21d9744e0e74 100644 (file)
@@ -1417,12 +1417,12 @@ handlers = {
     },
 
     RPL_WALLOPS: function (command) {
-        this.irc_connection.emit('user ' + this.irc_connection.event.split(' ')[1] + ' notice', {
+        this.irc_connection.emit('user ' + this.irc_connection.nick + ' notice', {
             from_server: false,
-            nick: 'WALLOPS:&nbsp;' + command.nick,
+            nick: 'WALLOPS: ' + command.nick,
             ident: command.ident,
             hostname: command.hostname,
-            target: this.irc_connection.event.split(' ')[1],
+            target: this.irc_connection.nick,
             msg: command.params[command.params.length - 1]
         });
     },