Changeset 12967
- Timestamp:
- 11/14/2023 11:12:02 PM (10 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/photo-directory/inc/posts.php
r12770 r12967 315 315 */ 316 316 public static function fix_front_page_pagination_count( $posts, $query ) { 317 if ( $query->is_home() ) {317 if ( $query->is_home() && $query->is_main_query() ) { 318 318 $front_page_count = get_option( 'posts_per_page' ); 319 319 $archives_per_page = 30; … … 323 323 if ( $total_posts > 0 ) { 324 324 $count += ceil( $total_posts / $archives_per_page ); 325 } 326 // Account for logged-out pagination limit on w.org. 327 if ( defined( '\WPORG_Page_Limiter::MAX_PAGES' ) && ! is_user_logged_in() ) { 328 $count = min( $count, \WPORG_Page_Limiter::MAX_PAGES ); 325 329 } 326 330 $query->max_num_pages = $count;
Note: See TracChangeset
for help on using the changeset viewer.