aboutsummaryrefslogtreecommitdiff
path: root/api
diff options
context:
space:
mode:
Diffstat (limited to 'api')
-rw-r--r--api/status.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/api/status.py b/api/status.py
index 6739c9d..a1b183a 100644
--- a/api/status.py
+++ b/api/status.py
@@ -1,10 +1,14 @@
from flask import Blueprint
+from db import cursor
status = Blueprint('status', __name__)
@status.route('/status')
def index():
- return ""
+ return {
+ # "users": int,
+ "games": len(cursor.execute ("select game_id from games where status = \"in_progress\"").fetchall())
+}
dynamic_route = ["/", status]