PluginProbe
Yoast SEO – Advanced SEO with real-time guidance and built-in AI / trunk
Yoast SEO – Advanced SEO with real-time guidance and built-in AI vtrunk
28.5 28.4 28.3 28.2 28.1 28.0 27.9 27.8 27.7 27.6 27.5 trunk 18.0 18.1 18.2 18.3 18.4 18.4.1 18.5 18.5.1 18.6 18.7 18.8 18.9 19.0 All 129 releases
← All changes | src/repositories/indexable-repository.php +10 -0 28.2 → trunk View file →
@@ -412,8 +412,18 @@
412 412 }
413 413
414 414 $indexables_to_create = \array_diff( $object_ids, $indexables_available );
415 415
416 + if ( ! empty( $indexables_to_create ) ) {
417 + // Warm the object caches for the whole batch, so each build below does not trigger its own uncached queries.
418 + if ( $object_type === 'post' ) {
419 + \_prime_post_caches( $indexables_to_create );
420 + }
421 + elseif ( $object_type === 'term' ) {
422 + \_prime_term_caches( $indexables_to_create );
423 + }
424 + }
425 +
416 426 foreach ( $indexables_to_create as $indexable_to_create ) {
417 427 $indexables[] = $this->builder->build_for_id_and_type( $indexable_to_create, $object_type );
418 428 }
419 429 }