Skip to content

Commit

Permalink
index: override path with /socket.io
Browse files Browse the repository at this point in the history
  • Loading branch information
rauchg committed Dec 17, 2012
1 parent 98c4bb6 commit fc65ed6
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,11 @@ Server.prototype.attach = function(srv, opts){
srv.listen(port);
}

debug('creating engine.io instance', opts);
// set engine.io path to `/socket.io`
opts = opts || {};
opts.path = opts.path || '/socket.io';

debug('creating engine.io instance with opts %j', opts);
if (this._static) this.serve(srv);
srv = engine.attach(srv, opts);
this.bind(srv);
Expand Down

0 comments on commit fc65ed6

Please sign in to comment.