[buddypress-trac] [BuddyPress Trac] #7935: bp_core_new_nav_default() not working since v3.0.0

buddypress-trac noreply at wordpress.org
Thu Nov 15 20:14:03 UTC 2018

#7935: bp_core_new_nav_default() not working since v3.0.0
 Reporter:  r-a-y         |       Owner:  boonebgorges
     Type:  defect (bug)  |      Status:  closed
 Priority:  normal        |   Milestone:  4.0
Component:  Core          |     Version:  3.0.0
 Severity:  normal        |  Resolution:  fixed
 Keywords:  has-patch     |
Changes (by boonebgorges):

 * owner:  (none) => boonebgorges
 * status:  new => closed
 * resolution:   => fixed


 In [changeset:"12288" 12288]:
 #!CommitTicketReference repository="" revision="12288"
 Nav: Dynamically load component screen file when changing nav default.

 BP 3.0.0 moved most screen controllers into files that are loaded only
 viewing the component. This introduced a regression into
 `bp_core_new_nav_default()`, since the `screen_function` would not be
 (ie `! is_callable()`) at the time that the nav item is modified.

 We resolve this by loading the component's screen functions in
 `bp_core_new_nav_default()` when we detect that they're not present. To
 around cases where component slugs don't match the official component ID,
 which corresponds to the file path, we introduce a new 'component_id'
 to be used when registering a new nav item.

 Props imath, r-a-y.
 Fixes #7935.

Ticket URL: <https://buddypress.trac.wordpress.org/ticket/7935#comment:15>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac

More information about the buddypress-trac mailing list