Make WordPress Core


Ignore:
Timestamp:
10/15/2017 09:28:13 PM (9 years ago)
Author:
SergeyBiryukov
Message:

Widgets: In WP_Widget_Media, apply widget_title filter regardless of whether the title is empty, same as other widgets do.

Props Bsop.
Fixes #42226.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/widgets/class-wp-widget-media.php

    r41772 r41866  
    214214                echo $args['before_widget'];
    215215
    216                 if ( $instance['title'] ) {
    217 
    218                         /** This filter is documented in wp-includes/widgets/class-wp-widget-pages.php */
    219                         $title = apply_filters( 'widget_title', $instance['title'], $instance, $this->id_base );
     216                /** This filter is documented in wp-includes/widgets/class-wp-widget-pages.php */
     217                $title = apply_filters( 'widget_title', $instance['title'], $instance, $this->id_base );
     218
     219                if ( $title ) {
    220220                        echo $args['before_title'] . $title . $args['after_title'];
    221221                }
Note: See TracChangeset for help on using the changeset viewer.