[buddypress-trac] [BuddyPress] #2773: Add "pre-delete" hooks to groups component

buddypress-trac at lists.automattic.com buddypress-trac at lists.automattic.com
Fri Dec 24 14:01:35 UTC 2010


#2773: Add "pre-delete" hooks to groups component
--------------------------+--------------------------------
  Reporter:  vtowel       |      Owner:  kunalb
      Type:  enhancement  |     Status:  assigned
  Priority:  normal       |  Milestone:  1.3
 Component:  Groups       |    Version:  1.3
Resolution:               |   Keywords:  plugins, extending
--------------------------+--------------------------------
Changes (by kunalb):

 * cc: bhalla.kunal@… (added)
 * owner:   => kunalb
 * version:  1.2.5 => 1.3
 * status:  new => assigned


Comment:

 Having hooks at both ends seems to be the best way to go about it—but I'm
 worried about breaking plugins that expect the data to have been deleted
 by the time these filters are called.

 Ideally, I'd go about moving the commands up and add
 `groups_deleted_group` and `groups_removed_data_for_user` after the actual
 deletion—would that be fine? Or should I leave the given actions where
 they are and add `groups_pre_delete_group` and
 `groups_pre_remove_data_for_user` to the files (this is probably safer in
 terms of not breaking any existing plugins). Comments?

 Also, a cursory glance at friends, etc. indicates that this can be
 replicated across the components.

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


More information about the buddypress-trac mailing list