Bug #15216
closedBlog posts and comments from private sites shouldn't be visible in sitewide activity stream
0%
Description
Follow-up to #15134 and #14223.
If a site has set their privacy setting to either "I would like my site to be visible only to registered users of the CUNY Academic Commons", "I would like my site to be visible only to users I add to it" or "I would like my site to be visible only to its Admins", BuddyPress will record blog post and comment activity items for this site as public.
Fix coming shortly.
Related issues
Updated by Raymond Hoh almost 3 years ago
- Status changed from New to Staged for Production Release
Fixed in https://github.com/cuny-academic-commons/cac/commit/5c4eb7a3752c41b779b80debd8004c0f6be2ac35.
If a site is private, the fix will hide the blog-related activity item from being displayed sitewide.
Boone, I decided to add the fix directly into the bp-mpo-activity-filter
plugin as other sites using the plugin might benefit from it. I've also added a pull request here. In the PR, I note that BuddyPress will block the activity item from saving if the site visibility option is set to Discourage search engines from indexing this site
. We might want to mirror what BuddyPress is doing if the site's visibility setting is private, but I opted to hide the activity item sitewide for now.
I'm also going to run a script similar to https://redmine.gc.cuny.edu/issues/15134#note-5 to address blog activity items that should be hidden sitewide. Here's the MySQL query: select a.id from wp_bp_activity a left join wp_blogs b on (a.item_id = b.blog_id) where a.hide_sitewide = 0 and a.component = 'blogs' and b.public < 1
. I'll run the script to switch these activity items over tomorrow.
Update:
In the PR, I note that BuddyPress will block the activity item from saving if the site visibility option is set to
Discourage search engines from indexing this site
. We might want to mirror what BuddyPress is doing if the site's visibility setting is private
Disregard what I said here. #8075 allows for activity recording for sites with the visibility option set to "Discourage search engines from indexing this site"
or (blog_public = 0
), so we do not need to follow what BuddyPress does.
Updated by Raymond Hoh almost 3 years ago
- Related to Feature #8075: Non-public sites should generate activity items with hide_sitewide = 1 added
Updated by Boone Gorges almost 3 years ago
- Status changed from Staged for Production Release to Resolved