diff options
author | lonkaars <l.leblansch@gmail.com> | 2021-03-27 20:27:02 +0100 |
---|---|---|
committer | lonkaars <l.leblansch@gmail.com> | 2021-03-27 20:27:02 +0100 |
commit | 1f897d3f5ad11178cf4776ae4070c9d3e832f5f3 (patch) | |
tree | 9589c50d46ac78652068da8d8c0d2cd26b4db4a8 | |
parent | ac7aff3de98cbc26dc0826f297b504ccb0011295 (diff) |
game/accept fix + stuk dir in voerbak
-rw-r--r-- | api/game/accept.py | 2 | ||||
-rw-r--r-- | voerbak/stuk/readme.md | 3 | ||||
-rw-r--r-- | voerbak/stuk/stuk | 1 | ||||
-rw-r--r-- | voerbak/stuk/stuk2 | 1 |
4 files changed, 6 insertions, 1 deletions
diff --git a/api/game/accept.py b/api/game/accept.py index 36bc018..7aab697 100644 --- a/api/game/accept.py +++ b/api/game/accept.py @@ -14,7 +14,7 @@ join_game = Blueprint('game_accept', __name__) @join_game.route('/accept', methods = ['POST']) @auth_required("user") -def index(user_id): +def index(game_id): if cursor.execute("select status from games where game_id = ?", [game_id]).fetchone()[0] != "wait_for_opponent": return "", 403 diff --git a/voerbak/stuk/readme.md b/voerbak/stuk/readme.md new file mode 100644 index 0000000..67f48ad --- /dev/null +++ b/voerbak/stuk/readme.md @@ -0,0 +1,3 @@ +# Stuk + +These are games from the database that finished as won but they shouldn't've. These can be used as test cases for when I'll have enough motivation to write unit tests for voerbak. diff --git a/voerbak/stuk/stuk b/voerbak/stuk/stuk new file mode 100644 index 0000000..0c832dc --- /dev/null +++ b/voerbak/stuk/stuk @@ -0,0 +1 @@ +3,4,4,4,3,3,3,1,1,4,1,3,7,5,4,5,5,7,1,1,5,3,7,7,5,5,7,1,6,4,6,7,6,0 diff --git a/voerbak/stuk/stuk2 b/voerbak/stuk/stuk2 new file mode 100644 index 0000000..0fee69a --- /dev/null +++ b/voerbak/stuk/stuk2 @@ -0,0 +1 @@ +4,3,3,4,4,2,1,5,2,2,3,4,3,3,1,1,1,6,1,6,1,6,6,4,6,6,4,3,7,0 |