diff --git src/bp-core/bp-core-filters.php src/bp-core/bp-core-filters.php
index 0ef025a97..4b626bd85 100644
|
|
|
add_filter( 'bp_email_set_subject', 'sanitize_text_field', 6 );
|
| 62 | 62 | // Avatars. |
| 63 | 63 | add_filter( 'bp_core_fetch_avatar', 'bp_core_add_loading_lazy_attribute' ); |
| 64 | 64 | |
| | 65 | // Remove filter to 'get_pages" when the 'legacy' BuddyPress URL Parser is in use. |
| | 66 | add_filter( 'bp_core_get_query_parser', 'bp_core_check_query_parser', 11 ); |
| | 67 | |
| 65 | 68 | /** |
| 66 | 69 | * Template Compatibility. |
| 67 | 70 | * |
diff --git src/bp-core/bp-core-functions.php src/bp-core/bp-core-functions.php
index 19b5d4eb0..04ec6b199 100644
|
|
|
function bp_is_running_wp( $version, $compare = '>=' ) {
|
| 141 | 141 | |
| 142 | 142 | /** Functions *****************************************************************/ |
| 143 | 143 | |
| | 144 | /** |
| | 145 | * Remove filter to 'get_pages" when the 'legacy' BuddyPress URL Parser is in use. |
| | 146 | * |
| | 147 | * @since 12.0.0 |
| | 148 | * |
| | 149 | * @param string $retval The name of the parser in use. |
| | 150 | * |
| | 151 | * @return string $retval The name of the parser in use. |
| | 152 | */ |
| | 153 | function bp_core_check_query_parser( $retval ) { |
| | 154 | if ( 'legacy' === $retval ) { |
| | 155 | remove_filter( 'get_pages', 'bp_core_include_directory_on_front', 10 ); |
| | 156 | } |
| | 157 | |
| | 158 | return $retval; |
| | 159 | } |
| | 160 | |
| 144 | 161 | /** |
| 145 | 162 | * Get the BuddyPress URL Parser in use. |
| 146 | 163 | * |