tests passing
porting to socket.io