Skip to content

Commit

Permalink
Merge pull request #9 from rainlab-inc/bug-fix-last-updated-room
Browse files Browse the repository at this point in the history
Fixed last updated room's information
  • Loading branch information
nesimtunc authored May 12, 2020
2 parents 74954c2 + 308a2e9 commit 02ee1b7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion assets/js/socket.js
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ const connectToTheLobby = () => {
}

function getLatestUpdatedRoom(rooms) {
return rooms.reduce((m, v, i) => (v.last_updated > m.last_updated) && i ? v : m);
return rooms.reduce((m, v, i) => (v.updated_at > m.updated_at) && i ? v : m);
}

}
Expand Down

0 comments on commit 02ee1b7

Please sign in to comment.