mirror of
https://github.com/django/django.git
synced 2025-12-09 19:08:06 +00:00
Fixed #18807 -- Made 404.html and 500.html optional
Thanks Aymeric Augustin for the report and Jannis Leidel for the review.
This commit is contained in:
parent
864a0514b8
commit
8bd7b598b6
10 changed files with 58 additions and 50 deletions
|
|
@ -158,9 +158,7 @@ For more on middleware, read the :doc:`middleware docs
|
|||
:class:`~django.contrib.flatpages.middleware.FlatpageFallbackMiddleware`
|
||||
only steps in once another view has successfully produced a 404 response.
|
||||
If another view or middleware class attempts to produce a 404 but ends up
|
||||
raising an exception instead (such as a ``TemplateDoesNotExist``
|
||||
exception if your site does not have an appropriate template to
|
||||
use for HTTP 404 responses), the response will become an HTTP 500
|
||||
raising an exception instead, the response will become an HTTP 500
|
||||
("Internal Server Error") and the
|
||||
:class:`~django.contrib.flatpages.middleware.FlatpageFallbackMiddleware`
|
||||
will not attempt to serve a flat page.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue