simple conflicts are now handled correctly

This commit is contained in:
Kevin Jahns
2015-07-06 16:47:49 +02:00
parent 9d0373b85b
commit bf4d5f24a8
9 changed files with 114 additions and 121 deletions

View File

@@ -69,11 +69,11 @@ class Test extends AbstractConnector {
this.globalRoom = globalRoom;
}
send (userId, message) {
globalRoom.buffers[userId].push([this.userId, message]);
globalRoom.buffers[userId].push(JSON.parse(JSON.stringify([this.userId, message])));
}
broadcast (message) {
for (var key in globalRoom.buffers) {
globalRoom.buffers[key].push([this.userId, message]);
globalRoom.buffers[key].push(JSON.parse(JSON.stringify([this.userId, message])));
}
}
disconnect () {