Skip to content

Instantly share code, notes, and snippets.

@MauricioRobayo
Last active June 26, 2022 04:24
Show Gist options
  • Save MauricioRobayo/dc3b4c119f93253d0afa028f8cf469b0 to your computer and use it in GitHub Desktop.
Save MauricioRobayo/dc3b4c119f93253d0afa028f8cf469b0 to your computer and use it in GitHub Desktop.
http-exceptions.txt
Do not throw HTTP exceptions from non-HTTP flow control code.
It can be tempting when working on an API to throw HTTP exceptions everywhere.
The only application layer that can accurately determine what response to send to the client is the HTTP control flow layer.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment