[buddypress-trac] [BuddyPress Trac] #6693: Activity CPT tracking should handle deletion as well

buddypress-trac noreply at wordpress.org
Thu Oct 29 21:44:57 UTC 2015


#6693: Activity CPT tracking should handle deletion as well
----------------------------------+-----------------------
 Reporter:  r-a-y                 |       Owner:  r-a-y
     Type:  enhancement           |      Status:  assigned
 Priority:  normal                |   Milestone:  2.5
Component:  Component - Activity  |     Version:  2.2
 Severity:  normal                |  Resolution:
 Keywords:  needs-patch           |
----------------------------------+-----------------------

Comment (by slaFFik):

 I had the same task in one of my plugins.
 The hardest part is such:
 We have `wp_delete_post($post_id, $force = true)` - which is totally ok,
 its hook passes `$post_id` and we can completely delete activity.
 But there is also a `wp_trash_post()` or `wp_delete_post($post_id, $force
 = false)` - and we don't have a `trash` for activity entries.
 Personally I decided to ignore trash, so activity will still be there, and
 when trash will be emptied - only than activity will be deleted.

--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/6693#comment:3>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list