From 68a53b8749620642f69f730cddcf33bf393b5154 Mon Sep 17 00:00:00 2001 From: cuom1999 Date: Thu, 31 Mar 2022 01:09:38 -0500 Subject: [PATCH] Remove unlisted users from home page --- judge/views/blog.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/judge/views/blog.py b/judge/views/blog.py index b7855dd..f29fdac 100644 --- a/judge/views/blog.py +++ b/judge/views/blog.py @@ -66,9 +66,9 @@ class FeedView(ListView): visible_contests = Contest.get_visible_contests(self.request.user).filter(is_visible=True) - context['top_rated'] = Profile.objects.order_by('-rating')[:10] - context['top_scorer'] = Profile.objects.order_by('-performance_points')[:10] - + context['top_rated'] = Profile.objects.filter(is_unlisted=False).order_by('-rating')[:10] + context['top_scorer'] = Profile.objects.filter(is_unlisted=False).order_by('-performance_points')[:10] + print(context['top_rated']) return context