RPL_LUSERME: '255',
RPL_LOCALUSERS: '265',
RPL_GLOBALUSERS: '266',
+ RPL_AWAY: '301',
RPL_WHOISREGNICK: '307',
RPL_WHOISUSER: '311',
RPL_WHOISSERVER: '312',
msg: command.trailing
});
},
+ 'RPL_AWAY': function (command) {
+ this.irc_connection.emit('user ' + command.params[1] + ' whoisaway', {
+ nick: command.params[1],
+ reason: command.trailing
+ });
+ },
'RPL_WHOISUSER': function (command) {
this.irc_connection.emit('user ' + command.params[1] + ' whoisuser', {
nick: command.params[1],
msg: command.trailing.substr(1, command.trailing.length - 2)
});
} else {
- namespace = (command.params[0] == this.irc_connection.nick) ? 'user' : 'channel';
+ namespace = (command.params[0] == this.irc_connection.nick || command.params[0] == '*') ?
+ 'user' :
+ 'channel';
+
this.irc_connection.emit(namespace + ' ' + command.params[0] + ' notice', {
- nick: command.nick,
+ from_server: command.prefix ? true : false,
+ nick: command.nick || command.prefix || undefined,
ident: command.ident,
hostname: command.hostname,
target: command.params[0],
this.client.sendIrcCommand('notice', {
server: this.con_num,
+ from_server: true,
nick: command.prefix,
ident: '',
hostname: '',