fixed duplicates in dashboard

This commit is contained in:
Esther Kleinhenz
2018-12-19 18:44:14 +01:00
parent b2798a6630
commit 5a54647577
2 changed files with 36 additions and 1 deletions
+1 -1
View File
@@ -129,7 +129,7 @@ def tag_list(request):
log.info(tags_user)
for tag in tags_user:
query = Post.objects.filter(tags__in=[tag]).order_by('-published_date')
posts = posts | query
posts = list(set(posts)|set(query))
log.info(posts)
return render(request, 'tag_list.html', {'posts': posts})