mirror of
https://github.com/Thream/socketio-jwt.git
synced 2024-07-21 09:38:31 +02:00
update readme and fix #11
This commit is contained in:
parent
80aa8dc023
commit
f072f91120
@ -56,7 +56,11 @@ io.use(socketioJwt.authorize({
|
||||
///////////////////////////////
|
||||
|
||||
io.on('connection', function (socket) {
|
||||
console.log('hello! ', socket.handshake.decoded_token.name);
|
||||
// in socket.io < 1.0
|
||||
console.log('hello!', socket.handshake.decoded_token.name);
|
||||
|
||||
// in socket.io 1.0
|
||||
console.log('hello! ', socket.client.request.decoded_token.name);
|
||||
})
|
||||
```
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user