From 9d7ae0e230c5530ae938933af17265de74c9dd2b Mon Sep 17 00:00:00 2001 From: Victor Costa Date: Thu, 31 Jul 2014 10:02:50 -0300 Subject: [PATCH] Fix communities listing when sub_organizations plugin is enabled --- app/controllers/public/profile_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/public/profile_controller.rb b/app/controllers/public/profile_controller.rb index e855c28..0909c53 100644 --- a/app/controllers/public/profile_controller.rb +++ b/app/controllers/public/profile_controller.rb @@ -51,7 +51,7 @@ class ProfileController < PublicController def communities if is_cache_expired?(profile.communities_cache_key(params)) - @communities = profile.communities.includes(relations_to_include).paginate(:per_page => per_page, :page => params[:npage]) + @communities = profile.communities.includes(relations_to_include).paginate(:per_page => per_page, :page => params[:npage], :total_entries => profile.communities.count) end end -- libgit2 0.21.2