Skip to content

Commit 40764bb

Browse files
[feat] Remove the socket.io-parser dependency (#47)
That will allow to use a custom parser (see socketio/socket.io#2829).
1 parent fd086d7 commit 40764bb

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

index.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
*/
55

66
var Emitter = require('events').EventEmitter;
7-
var parser = require('socket.io-parser');
87

98
/**
109
* Module exports.
@@ -23,7 +22,7 @@ function Adapter(nsp){
2322
this.nsp = nsp;
2423
this.rooms = {};
2524
this.sids = {};
26-
this.encoder = new parser.Encoder();
25+
this.encoder = nsp.server.encoder;
2726
}
2827

2928
/**

package.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
},
99
"description": "",
1010
"dependencies": {
11-
"debug": "2.3.3",
12-
"socket.io-parser": "2.3.1"
11+
"debug": "2.3.3"
1312
}
1413
}

0 commit comments

Comments
 (0)