Consistent 'connection' rather than 'server' in events
authorDarren <darren@darrenwhitlen.com>
Sat, 10 May 2014 13:16:42 +0000 (14:16 +0100)
committerDarren <darren@darrenwhitlen.com>
Sat, 10 May 2014 13:16:42 +0000 (14:16 +0100)
client/src/models/gateway.js
server/irc/connection.js

index 97edc3edf75c915d6a38ff6fa817b69dc25db4b3..ab80bcc58de2e9e57563d1a2be14f6b9a75ccfef 100644 (file)
@@ -275,8 +275,8 @@ _kiwi.model.Gateway = function () {
 \r
 \r
         // Trigger the connection specific events (used by Network objects)\r
-        if (typeof data.server !== 'undefined') {\r
-            that.trigger('connection:' + data.server.toString(), {\r
+        if (typeof data.connection_id !== 'undefined') {\r
+            that.trigger('connection:' + data.connection_id.toString(), {\r
                 event_name: command,\r
                 event_data: data\r
             });\r
index 4d9a8e9aab6026213c101e308ae3e0af890a2774..2017d1f704f4929d9a4525729ae192ffa8935d9e 100644 (file)
@@ -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);
 };