# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+try:
+ from django.utils.deprecation import MiddlewareMixin
+except ImportError:
+ # Django < 1.10
+ MiddlewareMixin = object
+
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.