From 0844039f9d0b0ae0b2202f74fa37e9d0c54b157e Mon Sep 17 00:00:00 2001 From: Luciano Prestes Cavalcanti Date: Tue, 15 Sep 2015 17:31:34 +0200 Subject: [PATCH] Fix bug in visible_profiles of CommunitiesBlock --- lib/ext/communities_block.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ext/communities_block.rb b/lib/ext/communities_block.rb index d077e6d..4a5fcaa 100644 --- a/lib/ext/communities_block.rb +++ b/lib/ext/communities_block.rb @@ -22,7 +22,7 @@ class CommunitiesBlock valid_communities_string = Community.get_valid_communities_string Community.all.each{|community| delete_communities << community.id unless eval(valid_communities_string)} - visible_profiles = visible_profiles.where(["profiles.id NOT IN (?)", delete_communities]) + visible_profiles = visible_profiles.where(["profiles.id NOT IN (?)", delete_communities]) unless delete_communities.empty? if !prioritize_profiles_with_image return visible_profiles.all( -- libgit2 0.21.2