Fix categories count attribute to restrict to posts published on current site
This commit is contained in:
parent
250740916b
commit
d0cc19fa2a
1 changed files with 1 additions and 1 deletions
|
@ -46,7 +46,7 @@ class BlogCategory(TranslatableModel):
|
|||
|
||||
@property
|
||||
def count(self):
|
||||
return self.blog_posts.filter(publish=True).count()
|
||||
return self.blog_posts.published().count()
|
||||
|
||||
def get_absolute_url(self):
|
||||
lang = get_language()
|
||||
|
|
Loading…
Add table
Reference in a new issue