Skip to content

Commit

Permalink
document when the error handlers get invoked
Browse files Browse the repository at this point in the history
  • Loading branch information
ghedo committed Dec 19, 2011
1 parent d8e1523 commit 6f6888c
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,14 @@ has to be used:
tofu_rescue_with(ctx, 404, err404_handler_func);
~~~~
By default Tofu can handle some errors (like 404s or 500s) if no other handler
The error handlers get invoked in various situations:
* when there is an error in the backend (error 500)
* when no handler is defined to handle a specific request (error 404)
* when an handler returns a Tofu response with status in the range
`400 <= x < 600` (whatever error is set).
By default Tofu can handle some errors (i.e. 404s or 500s) if no other handler
has been defined in the application.
## EXTRA LIBRARIES
Expand Down

0 comments on commit 6f6888c

Please sign in to comment.