Make WordPress Core

Changeset 27682


Ignore:
Timestamp:
03/24/2014 02:38:31 PM (11 years ago)
Author:
wonderboymusic
Message:

Do not use the alternative if/elseif/else syntax in prepend_attachment() introduced in [27622], as per kovshenin.

Fixes #27243.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/post-template.php

    r27676 r27682  
    14471447        return $content;
    14481448
    1449     if ( wp_attachment_is_image() ):
     1449    if ( wp_attachment_is_image() ) {
    14501450        $p = '<p class="attachment">';
    14511451        // show the medium sized image representation of the attachment if available, and link to the raw file
    14521452        $p .= wp_get_attachment_link(0, 'medium', false);
    14531453        $p .= '</p>';
    1454     elseif ( 0 === strpos( $post->post_mime_type, 'video' ) ):
     1454    } elseif ( 0 === strpos( $post->post_mime_type, 'video' ) ) {
    14551455        $meta = wp_get_attachment_metadata( get_the_ID() );
    14561456        $atts = array( 'src' => wp_get_attachment_url() );
     
    14601460        }
    14611461        $p = wp_video_shortcode( $atts );
    1462     elseif ( 0 === strpos( $post->post_mime_type, 'audio' ) ):
     1462    } elseif ( 0 === strpos( $post->post_mime_type, 'audio' ) ) {
    14631463        $p = wp_audio_shortcode( array( 'src' => wp_get_attachment_url() ) );
    1464     endif;
     1464    }
    14651465
    14661466    /**
Note: See TracChangeset for help on using the changeset viewer.