Using id instead of name to identify other Wokas

This commit is contained in:
David Négrier 2021-12-17 11:54:37 +01:00 committed by PizZaKatZe
parent ab994183e5
commit 44ff9e30d5

View File

@ -239,7 +239,7 @@ export class GameRoom {
public sendToOthersInGroupIncludingUser(user: User, message: ServerToClientMessage): void {
user.group?.getUsers().forEach((currentUser: User) => {
if (currentUser.name !== user.name) {
if (currentUser.id !== user.id) {
currentUser.socket.write(message);
}
});