WordPress.org

Make WordPress Core

Ticket #22671: miqro-media-list.patch

File miqro-media-list.patch, 862 bytes (added by miqrogroove, 17 months ago)

Removes the broken links in the media library.

  • wp-admin/includes/class-wp-media-list-table.php

     
    416416                                        $actions['delete'] = "<a class='submitdelete'$delete_ays href='" . wp_nonce_url( "post.php?action=delete&amp;post=$post->ID", 'delete-post_' . $post->ID ) . "'>" . __( 'Delete Permanently' ) . "</a>"; 
    417417                                } 
    418418                        } 
    419                         if ( !$this->is_trash ) { 
     419                        if ( !$this->is_trash and 'auto-draft' != get_post_status( $post ) ) { 
    420420                                $title =_draft_or_post_title( $post->post_parent ); 
    421421                                $actions['view'] = '<a href="' . get_permalink( $post->ID ) . '" title="' . esc_attr( sprintf( __( 'View &#8220;%s&#8221;' ), $title ) ) . '" rel="permalink">' . __( 'View' ) . '</a>'; 
    422422                        }