In get_media_item()
, $tags
and $_tags
are set and never used.
See #27882. git-svn-id: https://develop.svn.wordpress.org/trunk@28297 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
fc624a4298
commit
d92f5aa154
@ -1306,12 +1306,6 @@ function get_media_item( $attachment_id, $args = null ) {
|
|||||||
$filename = esc_html( wp_basename( $post->guid ) );
|
$filename = esc_html( wp_basename( $post->guid ) );
|
||||||
$title = esc_attr( $post->post_title );
|
$title = esc_attr( $post->post_title );
|
||||||
|
|
||||||
if ( $_tags = get_the_tags( $attachment_id ) ) {
|
|
||||||
foreach ( $_tags as $tag )
|
|
||||||
$tags[] = $tag->name;
|
|
||||||
$tags = esc_attr( join( ', ', $tags ) );
|
|
||||||
}
|
|
||||||
|
|
||||||
$post_mime_types = get_post_mime_types();
|
$post_mime_types = get_post_mime_types();
|
||||||
$keys = array_keys( wp_match_mime_types( array_keys( $post_mime_types ), $post->post_mime_type ) );
|
$keys = array_keys( wp_match_mime_types( array_keys( $post_mime_types ), $post->post_mime_type ) );
|
||||||
$type = array_shift( $keys );
|
$type = array_shift( $keys );
|
||||||
|
Loading…
Reference in New Issue
Block a user