Merge branch 'master' into Share-players-position-using-Socket.IO
# Conflicts: # back/src/Controller/IoSocketController.ts
This commit is contained in:
@@ -11,7 +11,7 @@ export class IoSocketController{
|
||||
constructor(server : http.Server) {
|
||||
this.Io = socketIO(server);
|
||||
|
||||
//authentication with token. it will be decodes and stock in socket.
|
||||
// Authentication with token. it will be decoded and stored in the socket.
|
||||
this.Io.use( (socket: Socket, next) => {
|
||||
if (!socket.handshake.query || !socket.handshake.query.token) {
|
||||
return next(new Error('Authentication error'));
|
||||
@@ -136,4 +136,4 @@ export class IoSocketController{
|
||||
this.shareUsersPosition();
|
||||
}, 10);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user