Fixed #8020 -- Fixed paginator initialisation in sitemaps framework. Thanks,
John D'Agostino. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8231 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
44e407b7c6
commit
90b6e1438f
|
@ -54,9 +54,9 @@ class Sitemap:
|
|||
return obj.get_absolute_url()
|
||||
|
||||
def _get_paginator(self):
|
||||
if not hasattr(self, "paginator"):
|
||||
self.paginator = paginator.Paginator(self.items(), self.limit)
|
||||
return self.paginator
|
||||
if not hasattr(self, "_paginator"):
|
||||
self._paginator = paginator.Paginator(self.items(), self.limit)
|
||||
return self._paginator
|
||||
paginator = property(_get_paginator)
|
||||
|
||||
def get_urls(self, page=1):
|
||||
|
|
Loading…
Reference in New Issue