[buddypress-trac] [BuddyPress Trac] #9061: Rewrite Rules Built Even When Not Needed

buddypress-trac noreply at wordpress.org
Mon Jan 8 19:03:47 UTC 2024


#9061: Rewrite Rules Built Even When Not Needed
-------------------------+------------------------------
 Reporter:  sjregan      |       Owner:  (none)
     Type:  enhancement  |      Status:  new
 Priority:  normal       |   Milestone:  Awaiting Review
Component:  Core         |     Version:  12.0.0
 Severity:  normal       |  Resolution:
 Keywords:               |
-------------------------+------------------------------

Comment (by sjregan):

 Again, I might be getting confused about this. But from what I see:

 In `bp-core-actions.php`:

 {{{#!php
 add_action( 'bp_init', 'bp_add_rewrite_rules',       30 );
 }}}


 In `bp-core-dependency.php`


 {{{#!php
 function bp_add_rewrite_rules() {
         do_action( 'bp_add_rewrite_rules' );
 }
 }}}



 In `class-bp-component.php`

 {{{#!php
 add_action( 'bp_add_rewrite_rules',      array( $this, 'add_rewrite_rules'
 ), 10, 0 );

 }}}



 Does this not mean the `add_rewrite_rules` component method is called on
 every page execution, or every active component?

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


More information about the buddypress-trac mailing list