From cbdab563a543b5ed99363f491e1f9df3db9caa0b Mon Sep 17 00:00:00 2001 From: Darren Date: Sat, 10 May 2014 14:16:42 +0100 Subject: [PATCH] Consistent 'connection' rather than 'server' in events --- client/src/models/gateway.js | 4 ++-- server/irc/connection.js | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/client/src/models/gateway.js b/client/src/models/gateway.js index 97edc3e..ab80bcc 100644 --- a/client/src/models/gateway.js +++ b/client/src/models/gateway.js @@ -275,8 +275,8 @@ _kiwi.model.Gateway = function () { // Trigger the connection specific events (used by Network objects) - if (typeof data.server !== 'undefined') { - that.trigger('connection:' + data.server.toString(), { + if (typeof data.connection_id !== 'undefined') { + that.trigger('connection:' + data.connection_id.toString(), { event_name: command, event_data: data }); diff --git a/server/irc/connection.js b/server/irc/connection.js index 4d9a8e9..2017d1f 100644 --- a/server/irc/connection.js +++ b/server/irc/connection.js @@ -308,7 +308,7 @@ IrcConnection.prototype.connect = function () { * Send an event to the client */ IrcConnection.prototype.clientEvent = function (event_name, data, callback) { - data.server = this.con_num; + data.connection_id = this.con_num; this.state.sendIrcCommand(event_name, data, callback); }; -- 2.25.1