Revert [22675]. wp_mime_type_icon() is more accurate when given a post ID, rather than a mime type. The "speed" mostly comes down to the ordering of cache hits, rather than any performance issues like #22503. see #21390.
git-svn-id: https://develop.svn.wordpress.org/trunk@22677 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
52cc02a9be
commit
870d1d05db
@ -1261,7 +1261,7 @@ function wp_prepare_attachment_for_js( $attachment ) {
|
||||
'mime' => $attachment->post_mime_type,
|
||||
'type' => $type,
|
||||
'subtype' => $subtype,
|
||||
'icon' => wp_mime_type_icon( $attachment->post_mime_type ),
|
||||
'icon' => wp_mime_type_icon( $attachment->ID ),
|
||||
'dateFormatted' => mysql2date( get_option('date_format'), $attachment->post_date ),
|
||||
);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user