diff --git a/username_to_uuid.py b/username_to_uuid.py index 0e40a3d..afc596e 100644 --- a/username_to_uuid.py +++ b/username_to_uuid.py @@ -33,6 +33,9 @@ class UsernameToUUID: return "" json_data = json.loads(response) - uuid = json_data['id'] + try: + uuid = json_data['id'] + except KeyError as e: + print("KeyError raised:", e); return uuid