Changeset 54941
- Timestamp:
- 12/06/2022 07:22:24 PM (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/includes/class-wp-media-list-table.php
r54661 r54941 111 111 ) 112 112 ); 113 114 update_post_parent_caches( $wp_query->posts ); 113 if ( $wp_query->posts ) { 114 update_post_thumbnail_cache( $wp_query ); 115 update_post_parent_caches( $wp_query->posts ); 116 } 115 117 } 116 118 … … 425 427 list( $mime ) = explode( '/', $post->post_mime_type ); 426 428 429 $attachment_id = $post->ID; 430 431 if ( has_post_thumbnail( $post ) ) { 432 $thumbnail_id = get_post_thumbnail_id( $post ); 433 434 if ( ! empty( $thumbnail_id ) ) { 435 $attachment_id = $thumbnail_id; 436 } 437 } 438 427 439 $title = _draft_or_post_title(); 428 $thumb = wp_get_attachment_image( $ post->ID, array( 60, 60 ), true, array( 'alt' => '' ) );440 $thumb = wp_get_attachment_image( $attachment_id, array( 60, 60 ), true, array( 'alt' => '' ) ); 429 441 $link_start = ''; 430 442 $link_end = '';
Note: See TracChangeset
for help on using the changeset viewer.