[wp-trac] [WordPress Trac] #33499: Allow `$autoload` to be set in `WP_Customize_Setting::_update_option()`

WordPress Trac noreply at wordpress.org
Fri Aug 21 22:12:01 UTC 2015


#33499: Allow `$autoload` to be set in `WP_Customize_Setting::_update_option()`
-------------------------+------------------
 Reporter:  dlh          |       Owner:
     Type:  enhancement  |      Status:  new
 Priority:  normal       |   Milestone:  4.4
Component:  Customize    |     Version:
 Severity:  normal       |  Resolution:
 Keywords:  has-patch    |     Focuses:
-------------------------+------------------

Comment (by dlh):

 Maybe it's so unlikely as to not worry about, but if I'm following
 correctly, wouldn't `autoload` bounce around if I registered:

 {{{#!php
 <?php

 $wp_customize->add_setting( 'foo[first]', array(
     'type' => 'option',
     'autoload' => false,
 ) );

 $wp_customize->add_setting( 'foo[second]', array(
     'type' => 'option',
     'autoload' => true,
 ) );
 }}}

 I also wondered whether it would be unexpected that an entire option's
 `autoload` could be affected by someone customizing only one part of it,
 in the case of arrays.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/33499#comment:4>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list