From: Ben Beltran Date: Wed, 18 Sep 2013 16:38:58 +0000 (-0500) Subject: Uses proper socket.io dependency X-Git-Url: https://git.r.bdr.sh/rbdr/cologne/commitdiff_plain/e1387420f0cd9a846445b76affb702037f841d26?ds=inline Uses proper socket.io dependency --- diff --git a/lib/loggers/socket.js b/lib/loggers/socket.js index ea9d944..b057d77 100644 --- a/lib/loggers/socket.js +++ b/lib/loggers/socket.js @@ -4,6 +4,7 @@ // Load up dependencies if (typeof require === 'function') { var Ne = require('neon'); + var ioClient = require('socket.io-client'); Module = Ne.Module; Class = Ne.Class; } else { @@ -21,17 +22,17 @@ init : function (config) { var logger = this; - logger.socketIo = global.io - if (config) { for (property in config) { logger[property] = config[property]; } } - if (logger.socketIo) { - logger._socket = logger.socketIo.connect(logger.serverUrl); + if (!logger.socketIo) { + logger.socketIo = ioClient; } + + logger._socket = logger.socketIo.connect(logger.serverUrl); }, log : function () { diff --git a/package.json b/package.json index 66c40d6..68ce318 100644 --- a/package.json +++ b/package.json @@ -17,10 +17,10 @@ "url" : "http://github.com/ktlacaelel" } ], - "version" : "0.1.8", + "version" : "0.1.9", "dependencies" : { "neon" : "1.0.x", - "socket.io" : "0.9.x", + "socket.io-client" : "0.9.x", "colors" : "0.x.x", "emailjs" : "0.3.x", "microtime" : "0.3.x"