diff options
| author | Tom Christie | 2014-09-19 14:27:40 +0100 | 
|---|---|---|
| committer | Tom Christie | 2014-09-19 14:27:40 +0100 | 
| commit | e6d4445bbbb30531ea98164379cfb707bcc8415f (patch) | |
| tree | 1867b00a46765c86bae712aa5bd3d5cdd76fff52 /api-guide | |
| parent | 6192f6f0b360bea578501fff4b9cdfdaa865a9c6 (diff) | |
| download | django-rest-framework-e6d4445bbbb30531ea98164379cfb707bcc8415f.tar.bz2 | |
Version 2.4.3 release notes
Diffstat (limited to 'api-guide')
| -rw-r--r-- | api-guide/exceptions.html | 2 | 
1 files changed, 1 insertions, 1 deletions
| diff --git a/api-guide/exceptions.html b/api-guide/exceptions.html index 10d70239..adbf5b88 100644 --- a/api-guide/exceptions.html +++ b/api-guide/exceptions.html @@ -274,7 +274,7 @@ def custom_exception_handler(exc):  <h1 id="api-reference">API Reference</h1>  <h2 id="apiexception">APIException</h2>  <p><strong>Signature:</strong> <code>APIException()</code></p> -<p>The <strong>base class</strong> for all exceptions raised inside REST framework.</p> +<p>The <strong>base class</strong> for all exceptions raised inside an <code>APIView</code> class or <code>@api_view</code>.</p>  <p>To provide a custom exception, subclass <code>APIException</code> and set the <code>.status_code</code> and <code>.default_detail</code> properties on the class.</p>  <p>For example, if your API relies on a third party service that may sometimes be unreachable, you might want to implement an exception for the "503 Service Unavailable" HTTP response code.  You could do this like so:</p>  <pre class="prettyprint lang-py"><code>from rest_framework.exceptions import APIException | 
