fix(users.py): update error message to be more generic and not reveal specific reason for username unavailability
fix(AdminPage/index.tsx): fix nullish assertion for create_at and updated_at properties to avoid potential errors fix(signUpPage/index.tsx): fix error handling to correctly display error message fix(types/components/index.ts): make id, create_at, and updated_at properties optional in UserInputType
This commit is contained in:
parent
d73b3b0b52
commit
cf8df6c62b
4 changed files with 7 additions and 7 deletions
|
|
@ -43,7 +43,7 @@ def add_user(
|
|||
db.refresh(new_user)
|
||||
except IntegrityError as e:
|
||||
db.rollback()
|
||||
raise HTTPException(status_code=400, detail="This username is unavailable as it has already been claimed. Please choose a different username.") from e
|
||||
raise HTTPException(status_code=400, detail="This username is unavailable.") from e
|
||||
|
||||
return new_user
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue