Navigation Menu

Skip to content

Commit

Permalink
Add note about shorthand
Browse files Browse the repository at this point in the history
  • Loading branch information
piroor committed Feb 19, 2014
1 parent 9f38316 commit 07022e6
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions reference/plugin/error/index.md
Expand Up @@ -12,6 +12,7 @@ layout: en
Any unhandled error raised from a plugin is returned as an [error response][] for the corresponding incoming message, with the status code `500` (means "internal error").

If you want formatted error information to be returned, then rescue errors and raise your custom errors inheriting `Droonga::ErrorMessage::BadRequest` or `Droonga::ErrorMessage::InternalServerError` instead of raw errors.
(By the way, they are already included to the base class of plugins so you can define your custom errors easily like: `class CustomError < BadRequest`)


## Built-in error classes {#builtin-errors}
Expand Down

0 comments on commit 07022e6

Please sign in to comment.