Skip to content

Fix: UnknownHashError in web.controllers.messages #661

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

Merged
merged 2 commits into from
Dec 2, 2024

Conversation

1yam
Copy link
Member

@1yam 1yam commented Dec 2, 2024

If an hash is not valid it's would return a error 500 instead of returning Bad Request.

Related Clickup or Jira tickets : ALEPH-110

Self proofreading checklist

  • Is my code clear enough and well documented
  • Are my files well typed
  • New translations have been added or updated if new strings have been introduced in the frontend
  • Database migrations file are included
  • Are there enough tests
  • Documentation has been included (for new feature)

Changes

Add try catch on ItemHash().

How to test

http://localhost:4024/api/v0/messages/{wrong_itemhash}
http://localhost:4024/api/v0/messages/{wrong_itemhash}/content
http://localhost:4024/api/v0/messages/{wrong_itemhash}/status

@1yam 1yam requested review from aliel and nesitor December 2, 2024 08:16
nesitor
nesitor previously approved these changes Dec 2, 2024
@nesitor nesitor merged commit b48d256 into main Dec 2, 2024
4 checks passed
@nesitor nesitor deleted the 1yam-fix-UnknownHashError branch December 2, 2024 09:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants