Permalink
Browse files

Remove logging

  • Loading branch information...
pksunkara committed Sep 18, 2011
1 parent e2d4604 commit ebc1cbc059b5a4f386dcbec4cd5c634b28839663
Showing with 0 additions and 3 deletions.
  1. +0 −3 app.js
View
3 app.js
@@ -61,21 +61,18 @@ io.sockets.on('connection', function(socket){
socket.emit('nickname?', {});
socket.on('nickname', function(data){
data = (data===null)? randomString() : data;
- console.log(data, 'joined the session');
socket.emit('members', sessions);
io.sockets.emit('join', {name: data, msg: data+' has joined the session'});
socket.set('nickname', data);
sessions.push(data);
});
socket.on('chat', function(data){
socket.get('nickname', function(err, nickname){
- console.log("msg from", nickname, ":", data);
io.sockets.emit('chat', nickname+': '+data);
});
});
socket.on('disconnect', function(){
socket.get('nickname', function(err, nickname){
- console.log(nickname, 'quit the session');
io.sockets.emit('quit', {name: nickname, msg: nickname+' has quit the session'});
sessions.splice(sessions.indexOf(nickname), 1);
});

0 comments on commit ebc1cbc

Please sign in to comment.