[buddypress-trac] [BuddyPress] #4586: Problem with registering multiple group extensions and group tabs

buddypress-trac noreply at wordpress.org
Mon Jun 3 14:02:10 UTC 2013


#4586: Problem with registering multiple group extensions and group tabs
--------------------------+-----------------------
 Reporter:  smninja       |       Owner:
     Type:  defect (bug)  |      Status:  reopened
 Priority:  normal        |   Milestone:  1.7
Component:  Groups        |     Version:
 Severity:  normal        |  Resolution:
 Keywords:  needs-patch   |
--------------------------+-----------------------
Changes (by boonebgorges):

 * version:  1.7 =>


Comment:

 "Version" refers to the version where the problem first popped up - please
 don't change it to a newer version. It so happens that this bug has been
 around pretty much forever.

 As of 1.7, it only occurs in the context of legacy themes - those that do
 not use theme compatibility. So, for those who were unable to reproduce,
 make sure you're testing using bp-default or a derivative.

 The cause: Just to make it clearer, I'll explain in terms of the
 refactored `BP_Group_Extension`. When you're on an Edit panel, the
 `setup_edit_hooks()` method is called
 https://buddypress.trac.wordpress.org/browser/trunk/bp-groups/bp-groups-
 classes.php#L2016. This method does roughly three things: adds the admin
 tabs (2034), hooks the admin tab content if necessary (2050), and then
 loads the template (2048, 2052). When using a legacy theme, calling
 `bp_core_load_template()` will include the template file, and then
 `exit()`. That means that group extensions will load, in order, until BP
 reaches the "current" admin tab, at which point loading stops. (

 It doesn't happen on theme compat because template loading is delayed
 until `template_include`. The fix for legacy mode is to delay template
 loading in the same way. Basically, because `setup_edit_hooks()` is called
 at `bp_actions:8`, we need to load the template sometime after
 `bp_actions:8`. `bp_screens` seems like the appropriate place. Fix coming
 momentarily.

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


More information about the buddypress-trac mailing list