Ticket #40201: 40201.2.patch
File 40201.2.patch, 954 bytes (added by , 8 years ago) |
---|
-
src/wp-includes/ms-blogs.php
445 445 * 446 446 * @global bool $_wp_suspend_cache_invalidation 447 447 * 448 * @param WP_Site $blog The site object to be cleared from cache.448 * @param WP_Site|int $blog The site object to be cleared from cache. 449 449 */ 450 450 function clean_blog_cache( $blog ) { 451 451 global $_wp_suspend_cache_invalidation; … … 454 454 return; 455 455 } 456 456 457 if ( is_object( $blog ) || is_int( $blog ) ) { 458 $blog = get_site( $blog ); 459 } 460 461 if ( ! ( $blog instanceof WP_Site ) ) { 462 return false; 463 } 464 457 465 $blog_id = $blog->blog_id; 458 466 $domain_path_key = md5( $blog->domain . $blog->path ); 459 467 … … 478 486 do_action( 'clean_site_cache', $blog_id, $blog, $domain_path_key ); 479 487 480 488 wp_cache_set( 'last_changed', microtime(), 'sites' ); 489 490 return true; 481 491 } 482 492 483 493 /**