[buddypress-trac] [BuddyPress] #3455: BuddyPress activity comment recording for Blog posts does not honour the WordPress post type visibility

buddypress-trac at lists.automattic.com buddypress-trac at lists.automattic.com
Mon Aug 8 22:07:23 UTC 2011


#3455: BuddyPress activity comment recording for Blog posts does not honour the
WordPress post type visibility
-------------------------+------------------------------
 Reporter:  sbrajesh     |       Owner:
     Type:  enhancement  |      Status:  new
 Priority:  normal       |   Milestone:  Awaiting Review
Component:  Blogs        |     Version:  1.5
 Severity:  minor        |  Resolution:
 Keywords:  has-patch    |
-------------------------+------------------------------

Comment (by boonebgorges):

 Strictly speaking, what we *should* be doing is not publish comments from
 non-posts at all. In bp_blogs_record_post(), we do this:
 http://buddypress.org/community/groups/how-to-and-
 troubleshooting/forum/topic/buddypress-1-5-theme-updated-themes-
 list/edit?_wpnonce=9c2e10c299

 This forces custom post types to create their own activity-posting
 function for new items, which puts the onus on plugin authors for this
 kind of thing.

 Since 'post' will always have ->public == true, we wouldn't need the extra
 overhead of get_post_type_object(). (not that it's much overhead, of
 course - it just grabs the object out of the global)

 In the future, I would like to have nicer API functions for custom post
 type activity posting (in my own plugins, I usually just copy over
 bp_blogs_record_comment() and bp_blogs_record_post(), which is silly).
 Such an API would definitely do the check that sbrajesh has suggested. But
 it is too late for 1.5.

 Thoughts?

-- 
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/3455#comment:1>
BuddyPress <http://buddypress.org/>
BuddyPress


More information about the buddypress-trac mailing list