diff --git a/app/community/routes.py b/app/community/routes.py index 971ff090..1e4c94d7 100644 --- a/app/community/routes.py +++ b/app/community/routes.py @@ -147,9 +147,9 @@ def show_community(community: Community): posts = posts.filter(Post.nsfw == False) content_filters = user_filters_posts(current_user.id) - domains_ids = blocked_domains(current_user.id) - if domains_ids: - posts = posts.filter(or_(Post.domain_id.not_in(domains_ids), Post.domain_id == None)) + domains_ids = blocked_domains(current_user.id) + if domains_ids: + posts = posts.filter(or_(Post.domain_id.not_in(domains_ids), Post.domain_id == None)) if sort == '' or sort == 'hot': posts = posts.order_by(desc(Post.ranking))