diff options
| author | syuilo <syuilotan@yahoo.co.jp> | 2018-03-07 19:03:32 +0900 |
|---|---|---|
| committer | syuilo <syuilotan@yahoo.co.jp> | 2018-03-07 19:03:32 +0900 |
| commit | 88d1ac2556b5eefae399c2186237e1fd32ff87ac (patch) | |
| tree | 7a8e2ed717d3a90182a905fe4e600b1eb17b047b /src/api/stream | |
| parent | v4008 (diff) | |
| download | sharkey-88d1ac2556b5eefae399c2186237e1fd32ff87ac.tar.gz sharkey-88d1ac2556b5eefae399c2186237e1fd32ff87ac.tar.bz2 sharkey-88d1ac2556b5eefae399c2186237e1fd32ff87ac.zip | |
Fix bug
Diffstat (limited to 'src/api/stream')
| -rw-r--r-- | src/api/stream/othello-game.ts | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/api/stream/othello-game.ts b/src/api/stream/othello-game.ts index 59d964777d..a5fb379e80 100644 --- a/src/api/stream/othello-game.ts +++ b/src/api/stream/othello-game.ts @@ -28,6 +28,7 @@ export default function(request: websocket.request, connection: websocket.connec const game = await Game.findOne({ _id: gameId }); if (game.is_ended) return; + if (!game.black_user_id.equals(user._id) && !game.white_user_id.equals(user._id)) return; const o = new Othello(); |