Make WordPress Core


Ignore:
Timestamp:
06/12/2015 10:53:39 PM (9 years ago)
Author:
westonruter
Message:

Customizer: Allow sections and panels to be exported to JS.

Also fix param docs for customize_dynamic_setting_class filter, and use require_once for class-wp-customize-manager.php in bootstrap function _wp_customize_include().

See #30737, #32576.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-wp-customize-manager.php

    r32658 r32744  
    910910             * @param string $setting_class WP_Customize_Setting or a subclass.
    911911             * @param string $setting_id    ID for dynamic setting, usually coming from `$_POST['customized']`.
    912              * @param string $setting_args  WP_Customize_Setting or a subclass.
     912             * @param array $setting_args  WP_Customize_Setting or a subclass.
    913913             */
    914914            $setting_class = apply_filters( 'customize_dynamic_setting_class', $setting_class, $setting_id, $setting_args );
     
    12061206
    12071207        foreach ( $this->sections as $section ) {
    1208             if ( ! $section->check_capabilities() || ! $section->controls ) {
     1208            if ( ! $section->check_capabilities() ) {
    12091209                continue;
    12101210            }
     
    12291229
    12301230        foreach ( $this->panels as $panel ) {
    1231             if ( ! $panel->check_capabilities() || ! $panel->sections ) {
     1231            if ( ! $panel->check_capabilities() ) {
    12321232                continue;
    12331233            }
Note: See TracChangeset for help on using the changeset viewer.