Skip to:
Content

BuddyPress.org

Ticket #4086: 4086.01.diff

File 4086.01.diff, 1.1 KB (added by boonebgorges, 12 years ago)
  • bp-core/bp-core-catchuri.php

    diff --git a/bp-core/bp-core-catchuri.php b/bp-core/bp-core-catchuri.php
    index 7ce8bf7..b0ba936 100644
    a b if ( !defined( 'ABSPATH' ) ) exit; 
    3737 *
    3838 */
    3939function bp_core_set_uri_globals() {
    40         global $bp, $current_blog;
    41 
     40        global $bp, $current_blog, $wp_rewrite;
     41       
    4242        // Don't catch URIs on non-root blogs unless multiblog mode is on
    4343        if ( !bp_is_root_blog() && !bp_is_multiblog_mode() )
    4444                return false;
    function bp_core_set_uri_globals() { 
    156156                        break;
    157157                }
    158158        }
    159 
     159       
    160160        // No exact match, so look for partials
    161161        if ( empty( $match ) ) {
    162162
    function bp_core_set_uri_globals() { 
    227227        }
    228228
    229229        // This is not a BuddyPress page, so just return.
    230         if ( !isset( $matches ) )
     230        if ( empty( $matches ) )
    231231                return false;
    232232
     233        $wp_rewrite->use_verbose_page_rules = false;
     234
    233235        // Find the offset. With $root_profile set, we fudge the offset down so later parsing works
    234236        $slug       = !empty ( $match ) ? explode( '/', $match->slug ) : '';
    235237        $uri_offset = empty( $root_profile ) ? 0 : -1;