WordPress.org

Make WordPress Core

Ticket #22764: class-wp-media-list-table.patch

File class-wp-media-list-table.patch, 821 bytes (added by eddiemoya, 3 years ago)

One-line fix, changes the "if" to an "elseif" as it should be.

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

    commit 81cc926fb23add920716e0fd4796edb4cfb9a932
    Author: Eddie Moya <eddie.moya@gmail.com>
    Date:   Wed Dec 5 15:16:27 2012 -0600
    
        Fixing a type in the logic where taxonomy terms are added to the media library.
    
    diff --git a/wp-admin/includes/class-wp-media-list-table.php b/wp-admin/includes/class-wp-media-list-table.php
    index 41c5080..2c2bf7c 100644
    a b foreach ( $columns as $column_name => $column_display_name ) { 
    343343        default: 
    344344                if ( 'categories' == $column_name ) 
    345345                        $taxonomy = 'category'; 
    346                 if ( 'tags' == $column_name ) 
     346                elseif ( 'tags' == $column_name ) 
    347347                        $taxonomy = 'post_tag'; 
    348348                elseif ( 0 === strpos( $column_name, 'taxonomy-' ) ) 
    349349                        $taxonomy = substr( $column_name, 9 );