Stop loading watched-by userids when accounts have chosen to hide that
list. Will help with high-membership communities (news, maintenance) as well
as generally just an optimization.
Patch by foxfirefey.
diffs (20 lines):
diff -r 164ba15fa675 -r 2e80116e2336 htdocs/userinfo.bml
--- a/htdocs/userinfo.bml Sat Sep 12 05:49:21 2009 +0000
+++ b/htdocs/userinfo.bml Sat Sep 12 05:52:45 2009 +0000
@@ -651,7 +651,15 @@ body<=
@trusted_userids = $u->trusted_userids if $u->is_personal;
@trusted_by_userids = $u->trusted_by_userids if $u->is_personal ||
$u->is_identity;
@watched_userids = $u->watched_userids if $u->is_personal ||
$u->is_identity;
- @watched_by_userids = $u->watched_by_userids unless $u->is_syndicated;
+ @watched_by_userids = $u->watched_by_userids unless $u->is_syndicated
||
+ # This is kind of a hack; we don't want to load these for
communities with lots
+ # of subscribers because the profile page chokes and dies. This
won't load them
+ # if the option to hide subscribers is set and the person cannot
manage the communities.
+ # It means the profile page is still broken to people who manage
the community, though, but
+ # it doesn't break things for smaller communities by not loading
them for the admins.
+ # FIXME: This overall situation of profile pages choking up for
large amounts of subscribers or members
+ # needs to be fixed in a more elegant and useful way.
+ ( $u->prop( 'opt_hidefriendofs' ) && ( !$remote ||
!$remote->can_manage( $u ) ) );
}
my @members_userids = $u->member_userids if $u->is_community;
_______________________________________________
dw-changelog mailing list
[email protected]
http://lists.dwscoalition.org/mailman/listinfo/dw-changelog