Skip to content

[BUG] - Unmeaningful database error message #23

@wenjie-mo

Description

@wenjie-mo

Description

If database connection is failed (such as due to a wrong password), the HTTP request returns unrelated error message.

Steps to Reproduce

Steps to reproduce the bug:

  • Use a wrong password for MySQL in application.properties
  • Send a register request through Postman
  • An unrelated error "duplicate username or email" appears

Expected Behavior

Should give more meaningful error message such as "Database connection failed".

Relevant screenshots

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions