From d1a8a7d45a36d698f2e75f9597fa645eb6de22a6 Mon Sep 17 00:00:00 2001 From: SuperCheng Date: Sun, 30 Jun 2019 16:24:37 -0400 Subject: [PATCH] Fix readme file Paginator constructor --- README.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.rst b/README.rst index 47bef4c..8fe760d 100644 --- a/README.rst +++ b/README.rst @@ -108,7 +108,7 @@ view file: **views.py** from django.shortcuts import render_to_response from pure_pagination import Paginator, EmptyPage, PageNotAnInteger - + from ${YOUR_APP}.settings import PAGINATION_SETTINGS def index(request): @@ -120,8 +120,8 @@ view file: **views.py** objects = ['john', 'edward', 'josh', 'frank'] # Provide Paginator with the request object for complete querystring generation - - p = Paginator(objects, request=request) + # 2nd Param is required here + p = Paginator(objects, PAGINATION_SETTINGS['PAGE_RANGE_DISPLAYED'], request=request) people = p.page(page)