Add new NotSupported exception.

remotes/origin/enhancement/email-actions
Andrey Antukh 2014-04-19 22:56:17 +02:00
parent 48d6d0cf28
commit a1dba18d33
1 changed files with 5 additions and 0 deletions

View File

@ -29,6 +29,11 @@ class NotFound(BaseException):
default_detail = _('Not found.') default_detail = _('Not found.')
class NotSupported(BaseException):
status_code = status.HTTP_405_METHOD_NOT_ALLOWED
default_detail = _("Method not supported for this endpoint.")
class BadRequest(BaseException): class BadRequest(BaseException):
""" """
Exception used on bad arguments detected Exception used on bad arguments detected