part: 'part', join: 'join', action: 'action', ctcp: 'ctcp',\r
ctcpRequest: 'ctcpRequest', ctcpResponse: 'ctcpResponse',\r
notice: 'notice', msg: 'privmsg', changeNick: 'changeNick',\r
- channelInfo: 'channelInfo', mode: 'mode'\r
+ channelInfo: 'channelInfo', mode: 'mode', quit: 'quit'\r
};\r
\r
// Proxy each gateway method\r
'command:kick': kickCommand,
'command:clear': clearCommand,
'command:ctcp': ctcpCommand,
+ 'command:quit': quitCommand,
'command:server': serverCommand,
'command:whois': whoisCommand,
'command:whowas': whowasCommand,
}
+ function quitCommand (ev) {
+ var network = this.app.connections.active_connection;
+
+ if (!network)
+ return;
+
+ network.gateway.quit(ev.params.join(' '));
+ }
+
+
function serverCommand (ev) {
var that = this,
server, port, ssl, password, nick,
\r
\r
quit: function (irc_connection, callback, args) {\r
- websocket.ircConnection.end('QUIT :' + args.message + '\r\n');\r
- websocket.sentQUIT = true;\r
- websocket.ircConnection.destroySoon();\r
- websocket.disconnect();\r
+ irc_connection.end('QUIT :' + (args.message||''));\r
},\r
\r
\r