8a541fbbec719ebba441aac262387e3c9afed8f2
[django-pagination.git] / pagination / middleware.py
1 class PaginationMiddleware(object):
2     def process_request(self, request):
3         try:
4             request.page = int(request['page'])
5         except KeyError:
6             request.page = 1