Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fixed a bug in server where we were trying at access player "a"'s rating where it should have been player "b"'s. It looks like this caused an error trying to access a player's rating (index a nil value) because we didn't check if a user_id or a if that user exists on the leaderboard before getting the rating for that user_id exists before we tried to use it. I think it's fixed now. These tests ran as expected, though I didn't try them before this fix was applied Bob asks for a match with Alice Alice asks for a match (accepts) Alice gets player_number 1 Bob gets player_number 2 Bob leaves Alice asks Bob for a match Bob Accepts Bob gets player_number 1 Alice gets player_number 2 Alice wins a ranked match and gets the points for it. Alice leaves Bob asks Alice for a match alice gets player_number 1 bob gets player_number 2 bob wins and gets the points Alice wins and gets the points.
- Loading branch information