From fe5b5fc47cd84324f80aa262b7b1dcaa93babbd2 Mon Sep 17 00:00:00 2001 From: Benjamin Dauvergne Date: Fri, 15 May 2020 16:08:04 +0200 Subject: [PATCH] dj22: use MiddlewareMixin --- src/authentic2_cut/middlewares.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/authentic2_cut/middlewares.py b/src/authentic2_cut/middlewares.py index 8f7020a..13c58a5 100644 --- a/src/authentic2_cut/middlewares.py +++ b/src/authentic2_cut/middlewares.py @@ -1,10 +1,11 @@ from django.conf import settings from django.utils.six.moves.urllib import parse as urlparse +from django.utils.deprecation import MiddlewareMixin from authentic2.utils import same_domain, redirect -class CUTMiddleware(object): +class CUTMiddleware(MiddlewareMixin): '''Extract requesting domain from URL and set value on request and in session. Domains extracted from ?next= of ?redirect_uri= parameters are matched against the