[buddypress-trac] [BuddyPress] #4955: Improvements to BP_Group_Extension

buddypress-trac noreply at wordpress.org
Fri May 3 03:15:11 UTC 2013


#4955: Improvements to BP_Group_Extension
--------------------------+---------------------------
 Reporter:  boonebgorges  |       Owner:  boonebgorges
     Type:  task          |      Status:  new
 Priority:  high          |   Milestone:  1.8
Component:  Groups        |     Version:
 Severity:  major         |  Resolution:
 Keywords:                |
--------------------------+---------------------------

Comment (by boonebgorges):

 The purpose of the `call_edit_screen()` method is to pass the group_id
 param directly to the `edit_screen()` callback. We need the middleman
 because `call_edit_screen()` (and, previously, `edit_screen()` itself) is
 hooked to `bp_template_content`. The only way to pass a value to a
 callback on a WP action is to pass it as an additional parameter to
 `do_action()`, eg `do_action( 'bp_template_content',
 bp_get_current_group_id() )`. But doing this would require modifying
 template files, which won't work for backward compatibility (and is also
 ugly). Having the `call_` method allows for full backward compatibility
 with existing themes and `BP_Group_Extension` plugins.

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


More information about the buddypress-trac mailing list