lib/index.js
function attachToHttpServer(httpServer, onConnectionCallback) {
  // socket.io 
  var socketIoOptions = extend({}, {
    path: config.socketPath
  });
  var sockets = io.listen(httpServer, socketIoOptions);
  debug("Attaching to http.Server");
  return attachToSocketIo(sockets, onConnectionCallback);

}
function attachToHttpServer(httpServer, onConnectionCallback) {
  // socket.io 
  var socketIoOptions = extend({}, {
    path: config.socketPath
  });
  var sockets = io.listen(httpServer, socketIoOptions);
  debug("Attaching to http.Server");
  return attachToSocketIo(sockets, onConnectionCallback);

}
function attachToHttpServer ( httpServer , onConnectionCallback ) { // socket.io  var socketIoOptions = extend ( { } , { path : config . socketPath } ) ; var sockets = io . listen ( httpServer , socketIoOptions ) ; debug ( "Attaching to http.Server" ) ; return attachToSocketIo ( sockets , onConnectionCallback ) ; }
Listen for socket.io events on httpServer.

@param {http.Server} httpServer. The server to attach socket.io to.
@param {Function} onConnectionCallback. Called when a socket client connects.
- @param {Error} err. Null if nothing bad happened.
- @param {EventEmitter} client. Event client.
Listen for socket . io events on httpServer .