[wp-trac] [WordPress Trac] #39221: Customize: Prevent setting previewing logic when settings will be saved

WordPress Trac noreply at wordpress.org
Thu May 18 18:44:19 UTC 2017


#39221: Customize: Prevent setting previewing logic when settings will be saved
--------------------------+--------------------
 Reporter:  westonruter   |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  4.8.1
Component:  Customize     |     Version:
 Severity:  normal        |  Resolution:
 Keywords:  needs-patch   |     Focuses:
--------------------------+--------------------
Changes (by westonruter):

 * milestone:  Future Release => 4.8.1


Comment:

 @stubgo excellent. Great feedback. I wonder what the best solution would
 be for this. Maybe there should be a `skip_setting_preview` argument that
 is added to the the `WP_Customize_Manager` constructor args that when
 supplied would be checked for whether or not `preview` should be called on
 each setting instead of hackily looking at the current Ajax action? The
 argument could default to `false`, but then in `_wp_customize_include()`
 it could then look at supplying the `skip_setting_preview` arg if doing
 the ajax action or something. Then in the changeset endpoint, where you
 are directly instantiating `WP_Customize_Manager` you would then
 explicitly pass in `skip_setting_preview=>true`. Seems like that would
 work but I'm not sure it is the most elegant. Thoughts?

 Milestoning for 4.8.1 to match #38900.

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


More information about the wp-trac mailing list