- if (typeof require === 'function') {
- global.Socket = Cobalt.Logger.Socket;
- } else {
- global.Cobalt.Logger.Socket = Cobalt.Logger.Socket;
+ logger._socket = logger.socketIo.connect(logger.serverUrl);
+ },
+
+ log : function () {
+ var i, messageArray = [];
+
+ for (i = 0; i < arguments.length; i++) {
+ messageArray.push(arguments[i]);
+ }
+
+ if (this._socket) {
+ this._socket.emit('log', messageArray);
+ }
+ }