Make WordPress Core

Ticket #32948: 32948.diff

File 32948.diff, 783 bytes (added by obenland, 9 years ago)
  • src/wp-admin/includes/media.php

     
    17401740 * @since 2.5.0
    17411741 */
    17421742function media_upload_header() {
    1743 
    17441743        $post_id = isset( $_REQUEST['post_id'] ) ? intval( $_REQUEST['post_id'] ) : 0;
    17451744
    1746         if ( ! empty( $post_id ) ) {
    1747                 $post_type = get_post_type( $post_id );
    1748         } else {
    1749                 $post_type = '';
    1750         }
    1751 
    1752         echo '<script type="text/javascript">post_id = ' . $post_id . ';post_type = ' . $post_type . ';</script>';
     1745        echo '<script type="text/javascript">post_id = ' . $post_id . ';</script>';
    17531746        if ( empty( $_GET['chromeless'] ) ) {
    17541747                echo '<div id="media-upload-header">';
    17551748                the_media_upload_tabs();