diff --git bp-core/bp-core-catchuri.php bp-core/bp-core-catchuri.php
index 0b07feb..9b98d13 100644
|
|
|
function bp_get_canonical_url( $args = array() ) {
|
| 628 | 628 | $front_page_component = array_search( $page_on_front, bp_core_get_directory_page_ids() ); |
| 629 | 629 | |
| 630 | 630 | // If requesting the front page component directory, canonical |
| 631 | | // URL is the front page |
| 632 | | if ( false !== $front_page_component && is_page( $page_on_front ) ) { |
| | 631 | // URL is the front page. We detect whether we're detecting a |
| | 632 | // component *directory* by checking that bp_current_action() |
| | 633 | // is empty - ie, this not a single item or a feed |
| | 634 | if ( false !== $front_page_component && bp_is_current_component( $front_page_component ) && ! bp_current_action() ) { |
| 633 | 635 | $bp->canonical_stack['canonical_url'] = trailingslashit( bp_get_root_domain() ); |
| 634 | 636 | |
| 635 | 637 | // Except when the front page is set to the registration page |