Changeset 55747 for trunk/src/wp-includes/ms-site.php
- Timestamp:
- 05/11/2023 11:13:10 AM (19 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/ms-site.php
r55702 r55747 341 341 * @since 5.1.0 Introduced the `$update_meta_cache` parameter. 342 342 * @since 6.1.0 This function is no longer marked as "private". 343 * @since 6.3.0 Use wp_lazyload_site_meta() for lazy-loading of site meta. 343 344 * 344 345 * @see update_site_cache() … … 355 356 $fresh_sites = $wpdb->get_results( sprintf( "SELECT * FROM $wpdb->blogs WHERE blog_id IN (%s)", implode( ',', array_map( 'intval', $non_cached_ids ) ) ) ); // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared 356 357 357 update_site_cache( $fresh_sites, $update_meta_cache ); 358 } 358 update_site_cache( $fresh_sites, false ); 359 } 360 361 if ( $update_meta_cache ) { 362 wp_lazyload_site_meta( $ids ); 363 } 364 } 365 366 /** 367 * Queue site meta for lazy-loading. 368 * 369 * @since 6.3.0 370 * 371 * @param array $site_ids List of site IDs. 372 */ 373 function wp_lazyload_site_meta( array $site_ids ) { 374 if ( empty( $site_ids ) ) { 375 return; 376 } 377 $lazyloader = wp_metadata_lazyloader(); 378 $lazyloader->queue_objects( 'blog', $site_ids ); 359 379 } 360 380
Note: See TracChangeset
for help on using the changeset viewer.