summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
Diffstat (limited to 'docs')
-rw-r--r--docs/internals/deprecation.txt4
-rw-r--r--docs/releases/3.1.txt3
-rw-r--r--docs/topics/http/middleware.txt4
3 files changed, 9 insertions, 2 deletions
diff --git a/docs/internals/deprecation.txt b/docs/internals/deprecation.txt
index 6b94bc1a3a..2d7a72ae2f 100644
--- a/docs/internals/deprecation.txt
+++ b/docs/internals/deprecation.txt
@@ -52,6 +52,10 @@ details on these changes.
* Support for the pre-Django 3.1 password reset tokens in the admin site (that
use the SHA-1 hashing algorithm) will be removed.
+* The ``get_request`` argument for
+ ``django.utils.deprecation.MiddlewareMixin.__init__()`` will be required and
+ won't accept ``None``.
+
See the :ref:`Django 3.1 release notes <deprecated-features-3.1>` for more
details on these changes.
diff --git a/docs/releases/3.1.txt b/docs/releases/3.1.txt
index 444cba34dc..59cfeb8157 100644
--- a/docs/releases/3.1.txt
+++ b/docs/releases/3.1.txt
@@ -525,6 +525,9 @@ Miscellaneous
be reproduced exactly as
``request.headers.get('x-requested-with') == 'XMLHttpRequest'``.
+* Passing ``None`` as the first argument to
+ ``django.utils.deprecation.MiddlewareMixin.__init__()`` is deprecated.
+
* The encoding format of cookies values used by
:class:`~django.contrib.messages.storage.cookie.CookieStorage` is different
from the format generated by older versions of Django. Support for the old
diff --git a/docs/topics/http/middleware.txt b/docs/topics/http/middleware.txt
index 3b96eae4e8..d72d39de5e 100644
--- a/docs/topics/http/middleware.txt
+++ b/docs/topics/http/middleware.txt
@@ -295,8 +295,8 @@ middleware classes that are compatible with both :setting:`MIDDLEWARE` and the
old ``MIDDLEWARE_CLASSES``. All middleware classes included with Django
are compatible with both settings.
-The mixin provides an ``__init__()`` method that accepts an optional
-``get_response`` argument and stores it in ``self.get_response``.
+The mixin provides an ``__init__()`` method that requires a ``get_response``
+argument and stores it in ``self.get_response``.
The ``__call__()`` method: