From 733c71a43d8f352e62609b625d47bfd0983905ad Mon Sep 17 00:00:00 2001 From: ctmbl Date: Wed, 18 Oct 2023 20:31:40 +0200 Subject: [PATCH] Fix bug when parsing position of a user with 0 points and position empty --- src/classes/user.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/classes/user.py b/src/classes/user.py index ac11afd..27d5867 100644 --- a/src/classes/user.py +++ b/src/classes/user.py @@ -39,7 +39,8 @@ def parse_rootme_user_data(data): idx = int(data["id_auteur"]) username = data["nom"] score = int(data["score"]) - rank = int(data["position"]) + _rank = data["position"] + rank = int(_rank) if _rank != "" else 9999999 nb_solves = len(data["validations"]) keys = User.keys()