Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve Error Handling for parse() in get_user_by_id_handler and update_contest_score_handler #6

Merged

Commits on Oct 1, 2024

  1. Improved error handling in get_user_by_id_handler:

    - Replaced `unwrap()` with proper error handling for parsing ID
    - Return 400 Bad Request if ID parsing fails
    - Return detailed error message if database query fails
    - Added handling for case when user is not found in the database
    HarshitShukla-dev committed Oct 1, 2024
    Configuration menu
    Copy the full SHA
    c2c61e6 View commit details
    Browse the repository at this point in the history
  2. Enhanced error handling in update_contest_score_handler:

    - Replaced `unwrap()` with robust error handling for ID parsing
    - Return 400 Bad Request if ID parsing fails
    - Added error handling for database update failures
    - Improved response messages for missing user cases
    HarshitShukla-dev committed Oct 1, 2024
    Configuration menu
    Copy the full SHA
    0a87a51 View commit details
    Browse the repository at this point in the history