From 2f0dd2ab9fdd12fb7befab0ac904371134b143a6 Mon Sep 17 00:00:00 2001 From: Frank Lanitz Date: Mon, 21 Jun 2021 18:41:02 +0200 Subject: [PATCH] users/login: Provider user_id together with token --- ki/routes.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/ki/routes.py b/ki/routes.py index e1e7604..88dfe18 100644 --- a/ki/routes.py +++ b/ki/routes.py @@ -99,8 +99,11 @@ def login(): if token is None: return make_response({}, 403) - return make_response({"token": token.token}) - + return make_response( + { + "token": token.token, + "user_id": token.user_id + }) @app.route("/users//profile") @token_auth