Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
07/16/2023 07:28:38 AM (17 months ago)
Author:
imath
Message:

Make sure directory rewrite rules match exact directory slugs

Before this change slugs beginning like directory slugs were wrongly consider as matches. Example: membership which begins like members was parsed as the Members directory.

See #4954
Fixes #8938
Closes https://github.com/buddypress/buddypress/pull/132

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-core/classes/class-bp-component.php

    r13513 r13518  
    11251125                    $query = 'index.php?' . $this->rewrite_ids['directory'] . '=1';
    11261126
    1127                     $rules[ $rule_key ]['regex'] = $regex;
     1127                    $rules[ $rule_key ]['regex'] = $regex . '/?$';
    11281128                    $rules[ $rule_key ]['query'] = $query;
    11291129                } else {
Note: See TracChangeset for help on using the changeset viewer.