From a864bab713cfd06a2daa4b8156cf582cf7a977fe Mon Sep 17 00:00:00 2001 From: AIIrondev Date: Sun, 26 Jul 2026 20:31:16 +0200 Subject: [PATCH] Fix of issues with the student user getting from the database users to student_cards --- Web/modules/database/user.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Web/modules/database/user.py b/Web/modules/database/user.py index b3e8643..b50c03d 100755 --- a/Web/modules/database/user.py +++ b/Web/modules/database/user.py @@ -594,8 +594,8 @@ def student_card_exists(student_card_id): return False client = MongoClient(cfg.MONGODB_HOST, cfg.MONGODB_PORT) db = _get_tenant_db(client) - users = db['users'] - exists = users.find_one({'StudentCardId': normalized}) is not None + users = db['student_cards'] + exists = users.find_one({'SchülerName': normalized}) is not None client.close() return exists @@ -607,8 +607,8 @@ def get_user_by_student_card(student_card_id): return None client = MongoClient(cfg.MONGODB_HOST, cfg.MONGODB_PORT) db = _get_tenant_db(client) - users = db['users'] - found_user = users.find_one({'StudentCardId': normalized}) + users = db['student_cards'] + found_user = users.find_one({'SchülerName': normalized}) client.close() return found_user