From: Darren Date: Mon, 29 Oct 2012 20:21:03 +0000 (+0000) Subject: Server: Updated stats command to new client store X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=170a3d8549d211ab60a4291bcb66d1f17b0bddca;p=KiwiIRC.git Server: Updated stats command to new client store --- diff --git a/server/kiwi.js b/server/kiwi.js index 1a4d313..e2f8758 100755 --- a/server/kiwi.js +++ b/server/kiwi.js @@ -99,7 +99,7 @@ global.clients = { // Start up a weblistener for each found in the config _.each(config.get().servers, function (server) { var wl = new WebListener(server, config.get().transports); - + wl.on('connection', function (client) { clients.add(client); }); @@ -140,7 +140,8 @@ process.stdin.on('data', function (buffered) { switch (data) { case 'stats': - console.log('Connected clients: ' + _.size(clients).toString()); + console.log('Connected clients: ' + _.size(global.clients.clients).toString()); + console.log('Num. remote hosts: ' + _.size(global.clients.addresses).toString()); break; case 'reconfig':