fix: [backend:exercise] Gracefully catch user_id without emails

This commit is contained in:
Sami Mokaddem 2024-07-09 14:05:00 +02:00
parent 8a64f84140
commit 7ed839d391

View file

@ -322,6 +322,8 @@ def get_progress():
completion_for_users = get_completion_for_users()
progress = {}
for user_id in completion_for_users.keys():
if user_id not in db.USER_ID_TO_EMAIL_MAPPING:
continue
progress[user_id] = {
'email': db.USER_ID_TO_EMAIL_MAPPING[user_id],
'exercises': {},