Use the attachment id to look up the mime type icon instead of the raw mime type string, as wp_mime_type_icon() runs a broader search when using an id. see #21390.

git-svn-id: http://core.svn.wordpress.org/trunk@22043 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Daryl Koopersmith 2012-09-27 06:07:56 +00:00
parent e3dc0220ff
commit 45c255a6a9
1 changed files with 1 additions and 1 deletions

View File

@ -1320,7 +1320,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 ),
);
if ( $meta && 'image' === $type ) {