| @@ -71,9 +71,13 @@ | ||
| 71 | 71 | $bbp = bbpress(); |
| 72 | 72 | |
| 73 | 73 | // Only call the search query if 's' is not empty |
| 74 | 74 | if ( ! empty( $r['s'] ) ) { |
| 75 | + $r['_bbp_public_topic_replies'] = true; | |
| 76 | + $r['_bbp_search_private_topic_replies'] = true; | |
| 77 | + add_filter( 'posts_where', 'bbp_public_topic_replies_where', 10, 2 ); | |
| 75 | 78 | $bbp->search_query = new WP_Query( $r ); |
| 79 | + remove_filter( 'posts_where', 'bbp_public_topic_replies_where', 10 ); | |
| 76 | 80 | } |
| 77 | 81 | |
| 78 | 82 | // Maybe prime last active posts |
| 79 | 83 | if ( ! empty( $r['update_post_family_cache'] ) ) { |
| @@ -350,9 +354,9 @@ | ||
| 350 | 354 | |
| 351 | 355 | /** |
| 352 | 356 | * Return the base URL used inside of pagination links |
| 353 | 357 | * |
| 354 | - * @since 2.6.0 bbPress (r6679) | |
| 358 | + * @since 2.6.0 bbPress (r6680) | |
| 355 | 359 | * |
| 356 | 360 | * @return string |
| 357 | 361 | */ |
| 358 | 362 | function bbp_get_search_pagination_base() { |