X-Git-Url: https://git.mdrn.pl/django-pagination.git/blobdiff_plain/4e7903dbfc111113131fe2e93dee06bed00b1b48..c32098c13826bb1b6f3781bfae7080d3fe9e03ff:/fnp_django_pagination/middleware.py diff --git a/fnp_django_pagination/middleware.py b/fnp_django_pagination/middleware.py index 580be43..02f8e7c 100644 --- a/fnp_django_pagination/middleware.py +++ b/fnp_django_pagination/middleware.py @@ -28,6 +28,8 @@ # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +from django.utils.deprecation import MiddlewareMixin + def get_page(self, suffix): """ @@ -45,7 +47,7 @@ def get_page(self, suffix): return 1 -class PaginationMiddleware(object): +class PaginationMiddleware(MiddlewareMixin): """ Inserts a variable representing the current page onto the request object if it exists in either **GET** or **POST** portions of the request.