Making WordPress.org

Changeset 12031


Ignore:
Timestamp:
08/26/2022 01:26:55 AM (4 years ago)
Author:
dd32
Message:

Support Forums: Improve performance for the all-topics view by limiting results to posts in the last month.

Fixes #6455.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/support-forums/inc/class-performance-optimizations.php

    r11547 r12031  
    295295                }
    296296
    297                 if ( bbp_is_single_view() && 'all-replies' === bbp_get_view_id() ) {
     297                // Limit all-replies & all-topics views to posts in the last month.
     298                if ( bbp_is_single_view() && in_array( bbp_get_view_id(), array( 'all-replies', 'all-topics' ) ) ) {
    298299                        add_filter( 'posts_where', array( $this, 'posts_in_last_month' ) );
    299300                }
Note: See TracChangeset for help on using the changeset viewer.