Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
06/18/2023 04:11:04 AM (12 months ago)
Author:
imath
Message:

BP Rewrites: optimize the code used to build URLs

The bp_members_get_path_chunks() & bp_groups_get_path_chunks() functions are making sure URL chunks are customized according to the slugs settings. Instead of redoing at many places all or some of the operations performed by these functions, update the code to build URLs so that it uses these functions.

See #4954
Fixes #8923
Closes https://github.com/buddypress/buddypress/pull/117

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-core/bp-core-filters.php

    r13481 r13503  
    12521252                    bp_members_get_user_url(
    12531253                        $user_obj->ID,
    1254                         array(
    1255                             'single_item_component' => bp_rewrites_get_slug( 'members', 'member_settings', bp_get_settings_slug() ),
    1256                             'single_item_action'    => bp_rewrites_get_slug( 'members', 'member_settings_notifications', 'notifications' ),
    1257                         )
     1254                        bp_members_get_path_chunks( array( bp_get_settings_slug(), 'notifications' ) )
    12581255                    )
    12591256                );
Note: See TracChangeset for help on using the changeset viewer.