WP_Query, pre_get_posts and offset
It helps to write problems down. After I haven’t used pre_get_posts extensively, I focused too much on that area for the cause, but it was the if clause. Changed to if ( ! is_admin() && $query->is_main_query() && ! is_post_type_archive( ‘cpt’ ) ) { return $query; } elseif ( ! is_admin() && $query->is_main_query() && is_post_type_archive( ‘cpt’ … Read more