Make WordPress Core


Ignore:
Timestamp:
10/02/2017 10:01:19 PM (8 years ago)
Author:
SergeyBiryukov
Message:

Widgets: Pass $instance to widget argument filters:

  • widget_archives_dropdown_args
  • widget_archives_args
  • widget_categories_dropdown_args
  • widget_categories_args
  • widget_meta_poweredby
  • widget_pages_args
  • widget_comments_args
  • widget_posts_args
  • widget_tag_cloud_args

See [33971] for widget_links_args and [34662] for widget_nav_menu_args.

Props Takahashi_Fumiki.
Fixes #38017.

File:
1 edited

Legend:

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

    r41162 r41685  
    5959         * @since 2.8.0
    6060         * @since 3.0.0 Added taxonomy drop-down.
     61         * @since 4.9.0 Added the `$instance` parameter.
    6162         *
    6263         * @see wp_tag_cloud()
    6364         *
    64          * @param array $args Args used for the tag cloud widget.
     65         * @param array $args     Args used for the tag cloud widget.
     66         * @param array $instance Array of settings for the current widget.
    6567         */
    6668        $tag_cloud = wp_tag_cloud( apply_filters( 'widget_tag_cloud_args', array(
     
    6870            'echo'       => false,
    6971            'show_count' => $show_count,
    70         ) ) );
     72        ), $instance ) );
    7173
    7274        if ( empty( $tag_cloud ) ) {
Note: See TracChangeset for help on using the changeset viewer.