Changeset 41205 for trunk/src/wp-includes/theme.php
- Timestamp:
- 08/02/2017 05:34:32 AM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/theme.php
r41193 r41205 2817 2817 } 2818 2818 2819 /* 2820 * Note that settings must be previewed even outside the customizer preview 2821 * and also in the customizer pane itself. This is to enable loading an existing 2822 * changeset into the customizer. Previewing the settings only has to be prevented 2823 * here in the case of a customize_save action because this will cause WP to think 2824 * there is nothing changed that needs to be saved. 2825 */ 2826 $is_customize_save_action = ( 2827 wp_doing_ajax() 2828 && 2829 isset( $_REQUEST['action'] ) 2830 && 2831 'customize_save' === wp_unslash( $_REQUEST['action'] ) 2832 ); 2833 $settings_previewed = ! $is_customize_save_action; 2834 2819 2835 require_once ABSPATH . WPINC . '/class-wp-customize-manager.php'; 2820 $GLOBALS['wp_customize'] = new WP_Customize_Manager( compact( 'changeset_uuid', 'theme', 'messenger_channel' ) );2836 $GLOBALS['wp_customize'] = new WP_Customize_Manager( compact( 'changeset_uuid', 'theme', 'messenger_channel', 'settings_previewed' ) ); 2821 2837 } 2822 2838 … … 2850 2866 if ( empty( $wp_customize ) ) { 2851 2867 require_once ABSPATH . WPINC . '/class-wp-customize-manager.php'; 2852 $wp_customize = new WP_Customize_Manager( array( 'changeset_uuid' => $changeset_post->post_name ) ); 2868 $wp_customize = new WP_Customize_Manager( array( 2869 'changeset_uuid' => $changeset_post->post_name, 2870 'settings_previewed' => false, 2871 ) ); 2853 2872 } 2854 2873
Note: See TracChangeset
for help on using the changeset viewer.